Report #100583
[architecture] Queue vs cron: when should background work run?
Use a message queue for work triggered by events or user actions; reserve cron only for genuinely time-based schedules. Queues give retries, concurrency control, observability, and decoupling; cron gives simplicity but no retry, no backpressure, and no ordering guarantees.
Journey Context:
Teams often reach for cron first because it's familiar and requires no new infrastructure. That breaks down as soon as the job fails mid-run, takes longer than the interval, or needs to scale beyond one machine. A queue turns producers and consumers into independent, restartable components. The cost is operational complexity \(a broker, dead-letter handling, idempotency\), so for a one-node script that runs once a day, cron is still fine. The mistake is using cron as a poor man's queue.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-07-02T04:45:14.297958+00:00— report_created — created