Skip to content

Ai 1240 - #191

Closed
kmandryk wants to merge 11 commits into
mainfrom
AI-1240
Closed

Ai 1240#191
kmandryk wants to merge 11 commits into
mainfrom
AI-1240

Conversation

@kmandryk

@kmandryk kmandryk commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

Summary

address upload-ocr bottleneck
AI-1240

Changes

Testing

Re-run payload-sizes large × 5 VU on the load-test instance to validate OOM/failure-rate acceptance criteria

dbarkowsky and others added 11 commits May 20, 2026 09:42
AI-1261 Frontend Error Page
Introduce an in-process UploadNormalizationLimiter to bound concurrent PDF/image normalization (Math.max(2, availableParallelism())). Start the original blob write concurrently with normalization to overlap I/O and CPU, await the original write before writing the normalized blob, and release the decoded upload buffer early to reduce peak memory. Move expensive pdf-lib parsing into normalizeToPdf (validateForUpload now does a cheap magic-byte probe for PDFs), add robust parse/error handling, and generate thumbnails from the normalized PDF bytes. Wire the limiter into the Document module/service, add unit tests for the limiter and updated upload behavior/order, and update documentation to describe the upload memory/concurrency model and API implications.
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