Skip to content
Theory · RabbitMQ failures and retries · lesson 1 of 7

Dead-letter exchanges

Rejected, expired and pushed-out letters from the shelf payments fall through the DLX chute onto the unclaimed shelf, one stamped rejected

A consumer rejected a payment without requeue, and the broker deleted it. An hour later it turns out the payment was real, and its processing failed because of a bug in the code that has since been fixed. There is nowhere to find the message: it is neither in the queue nor on the broker's disk. RabbitMQ can set such messages aside so that they are examined and processed again later.

In this lesson

  • DLX and DLQ
  • When a message goes to the DLX
  • The x-death header
  • Routing key
  • Quorum queues and losses
  • What to do with a DLQ
  • Common mistake
  • Key points