Is it possible to use Dead Letter Exchanges to handle both retrying a task and archiving tasks that failed more than retry_max
number of times?
Most articles I've read set it up so that when a task fails, it is nack
ed so the task is sent to a retry-queue
via a DLX. retry-queue
has a TTL and is configured to send the dead message back to worker-queue
.
What I would like to do is to send the message to a different queue, e.g.: dead-queue
, when the maximum number of retries fails for manual intervention later. Is this possible using nack
?
The diagram in the second answer here suggests that I can somehow nack
the message when the max retries is exceeded and send it to a "Fail Exchange" but I'm not sure how I can nack
the message and have it delivered to a different exchange.