Skip to content

Run text extraction from images serially#3111

Merged
pjrobertson merged 2 commits into
mainfrom
pjrobertson/serial-run-text-extraction
Apr 19, 2026
Merged

Run text extraction from images serially#3111
pjrobertson merged 2 commits into
mainfrom
pjrobertson/serial-run-text-extraction

Conversation

@pjrobertson
Copy link
Copy Markdown
Member

Avoids overwhelming resources when many images are being scanned (previously, it would fire of an unlimited number of background threads equal to the number of images being scanned).

Changes:

Replaced QSGCDAsync (global concurrent queue) with a dedicated DISPATCH_QUEUE_SERIAL queue at QOS_CLASS_UTILITY priority. This means image text recognition requests are processed one at a time on a low-priority background thread, instead of hundreds firing concurrently and starving the system.

@pjrobertson pjrobertson merged commit b1db387 into main Apr 19, 2026
2 checks passed
@pjrobertson pjrobertson deleted the pjrobertson/serial-run-text-extraction branch April 19, 2026 12:00
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.

1 participant