[rabbitmq-discuss] Vanishing of persistent messages on durable, auto-deleting queue with dead-lettering
matthias at rabbitmq.com
Mon Jul 16 19:03:29 BST 2012
On 16/07/12 11:37, Ernest Staszuk wrote:
> 2012-07-01 20:23, Matthias Radestock writes:
>> We deliberately kept the set of operations susceptible to
>> dead-lettering small, to avoid unintended consequences. It is possible
>> that actions like auto-deletion, queue lease expiry, explicit deletion
>> and purging should all trigger the dead-letter mechanism, but I'd like
>> to see compelling use cases first before making such a change.
> I will describe the case I am dealing with: We send some tasks to
> rabbit's exchange. To achieve load balancing at rpc servers
> x-consistent-hash is used. Auto-deleting queues with dead-lettering
> are fitting there perfectly, because when one of consuments goes down
> his queue is deleted and then new messages are distributed only
> between active consumers (due to auto-deleting) and also we can
> preserve badly processed commands for another try or examination in
> another queue (due to dead-lettering).
You do know that x-consistent-hash may lose some new messages when
queues are deleted, right? See the docs for details.
Anyway, leaving that issue aside for the moment...
> But as consequence of choosing auto-deleting queue also some part of
> messages (which won't be dead-lettered when queue will be discarded).
> As there are cases when loosing messages is not an option I think if
> actual behavior is consistent with spirit of dead-lettering's aims
> (imho to save undeliverable messages).
Sounds reasonable. And I guess a similar case could be made for queue
lease expiry. What about explicit deletion (i.e. invoking queue.delete)
or purging (queue.purge)?
More information about the rabbitmq-discuss