Repository navigation
perf: add optional host Poppler CLI fast path for PDF rendering - #793
Merged
Merged
Conversation
Lolle2000la
force-pushed
the
perf/pdf-poppler
branch
from
November 23, 2026 20:33
085cef2 to
53ddc39
Compare
This was referenced Nov 23, 2026
Lolle2000la
force-pushed
the
perf/pdf-poppler
branch
from
November 23, 2026 21:17
53ddc39 to
aa1b192
Compare
This was referenced Nov 23, 2026
Merged
Lolle2000la
force-pushed
the
perf/pdf-poppler
branch
from
November 24, 2026 06:00
aa1b192 to
8261cd4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Factored out of #785 so #785 can land as pure-Rust
hayro-only PDF support.feat/svg-support->masterresvgrefactor/media-architecture->masterfeat/doc-foundation->masterfeat/doc-pdf->masterhayroperf/pdf-poppler->masterfeat/doc-comics->masterCBZ,CB7,CBT,CBR) previews, caches, andComicInfo.xmlmetadatafeat/doc-epub->masterfeat/doc-office->masteroffice_oxide/calamine/XML/ODF), OS thumbnails, headless LibreOffice bridge, and isolated--lok-workerWhat this adds
crates/media-sort-backend/src/media/document/poppler_pipe.rsand wires it intodocument.rsanddocument/pdf.rs(render_pdf_thumbnail,load_pdf_preview, andextract_pdf_metadata) with automatic fallback tohayroon error.pdfinfo(with a 64-entryBoundedLru<CanonicalFileKey, _>cache) andpdftoppm(raw binaryP6PPM stdout stream) viacrate::processhelpers (new_hidden_command,run_command_capped,find_executable_on_path,path_starts_with_dash,is_sandboxed, 15 s timeout, 32 MiB stdout cap).!process::is_sandboxed()— i.e. skipped whenin_flatpak()or non-emptySNAP).AGENTS.mdand EN/DE/JAmedia-capabilities.mdxdocs to describe the optional host Poppler acceleration.Tradeoffs vs pure-Rust
hayropdftoppm/pdfinfoare onPATH, while pure-Rusthayroworks identically on all platforms without any host binary).Verification (Linux, post-rebase onto
master17560c9a)cargo fmt --all -- --check: passedcargo clippy --workspace --all-targets -- -D warnings: passedcargo test -p media-sort-backend --test document_tests: 17 passed, 0 failedcargo test -p media-sort-backend --lib poppler_pipe: 4 passed, 0 failedwebsite(format:check,lint,astro build): passed (59 pages built)