Skip to content

Fix support for streaming Web Publications with EPUB profile#731

Draft
mickael-menu wants to merge 1 commit intodevelopfrom
fix/webpub-epub
Draft

Fix support for streaming Web Publications with EPUB profile#731
mickael-menu wants to merge 1 commit intodevelopfrom
fix/webpub-epub

Conversation

@mickael-menu
Copy link
Member

Postponed for now.

Related to readium/mobile#40 and #652

// streamed manifest because it will fetch all the
// resources on the server.
if manifest.readingOrder.allAreHTML, isPackage {
$0.setSearchServiceFactory(StringSearchService.makeFactory())
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it would be desirable to have a SearchService for streamed WebPubs, but that it only fetches content, when/if used to actually search.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My comment was ambiguous, the SearchService and ContentService are already fetching the resources only when requested (when moving forward in the search iterator, for example). But this allows users to crawl multiple times all the resources of the server, if it does not provide a proper Web Search service. So I think this should be discouraged in the toolkit by default.

As a user of the toolkit, you can always add the StringSearchService yourself after parsing the publication, if you have some control over the server and are okay with potential crawling.

This could be alleviated by adding a CachingContainer when opening the publication, to cache the resources on the disk or in memory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants