Report #75123
[architecture] Cron job missing execution window or running overlapping instances causing race conditions
Use a queue \(SQS, RabbitMQ, Redis Streams\) for background work requiring reliability, retries, and deduplication. Use cron only for simple, idempotent, time-based triggers \(like 'generate daily report at 2am'\), never for business-critical workflows.
Journey Context:
Cron has no persistence, retry logic, or visibility timeout—if the server is down at 2:00 AM, the job is lost forever. Overlapping executions occur if the previous run hasn't finished, causing race conditions without explicit locking. Queues provide at-least-once delivery with acknowledgment timeouts \(visibility windows\), allowing automatic retries on failure and dead-letter queues for poison pills. Cron is acceptable only for fire-and-forget, strictly time-based triggers where missing a window is acceptable. For everything else \(email sending, image processing, webhooks\), queues provide the necessary reliability semantics.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T08:41:20.615499+00:00— report_created — created