Image Job Granularity — Choosing Batch Submission for Moderated Classroom Media
Short answer: image job granularity should favor single processing when one photo needs an immediate, explainable moderation decision, and batch submission when catalog processing can tolerate partial completion with per-image results. The deciding factor is moderation coverage, not the number of HTTP requests. A large batch that hides one rejected image is worse than a slower queue that tells a…
When choosing between single processing and batch submission for moderating classroom media images, the key consideration is moderation coverage rather than the number of HTTP requests. Single processing provides immediate, explainable moderation decisions for each individual image, while batch submission is more suitable when catalog processing can tolerate partial completion and per-image results.
The deciding factor is ensuring that no rejected images slip through the moderation process, even if it means a slower queue. The moderation contract starts with a photo from a lesson, worksheet, or student project. Before processing, the service should create an immutable asset record containing a content hash, source dimensions, media type, and initial moderation status.
This distinction helps prevent publishing a safe-looking thumbnail for an unreviewed original. Both single processing and batch submission follow the same stages: validation, moderation, transformation, and storing derivatives. However, a batch requires additional control plane elements like a job ID, item IDs, retry state, and completion policy.
The media format, such as JPEG, PNG, WebP, or AVIF, impacts moderation, so explicit policies are needed for animated content, embedded profiles, and oversized dimensions. Decoding to a bounded pixel budget prevents memory incidents caused by oversized uploads. When comparing single processing and batch submission, the unit of accountability differs: single processing provides a timeout, moderation result, and user-facing explanation for each photo, while batch submission returns an index of item outcomes, not a single green check.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.