Dead-Letter Queue
A dead-letter queue (DLQ) is a special queue that holds tasks or messages that failed processing after exhausting all retry attempts. Instead of silently dropping failed work, a DLQ preserves it for inspection, debugging, and manual reprocessing.
Why Dead-Letter Queues Matter
Without a DLQ, failed tasks vanish. You have no way to know what broke, why it broke, or how to recover. A DLQ provides:
- Visibility: See every task that failed and why
- Debugging: Inspect payloads, error messages, and retry history
- Recovery: Reprocess failed tasks after fixing the underlying issue
- Alerting: Trigger notifications when tasks land in the DLQ
How DLQs Work
- A task is picked up by a worker and execution is attempted
- If execution fails, the task is retried according to the retry policy
- After all retries are exhausted, the task is moved to the dead-letter queue
- An operator can inspect the failed task and either fix the issue and reprocess, or discard it
Dead-Letter Queues in AsyncQueue
AsyncQueue automatically routes failed tasks to a DLQ after exhausting retry attempts. From the dashboard, you can:
- View all failed tasks with full execution history
- Inspect the original payload and each retry attempt
- Reprocess individual tasks or bulk-retry all DLQ items
- Set up alerts for DLQ activity