[rabbitmq-discuss] Sematics of ACK/REQUEUE/DISCARD on a message
lists at zopyx.com
Thu May 6 06:28:25 BST 2010
-----BEGIN PGP SIGNED MESSAGE-----
Matthias Radestock wrote:
> Matthew Sackman wrote:
>> On Wed, May 05, 2010 at 07:51:35PM +0200, Andreas Jung wrote:
>>> Two questions:
>>> - - assuming a consumer could process a message with success - what is
>>> the difference in the message handling inside the queue between
>>> acknowledging it or discarding it - it will be removed from the queue
>>> in both cases?!
>> If you don't ack it, it will be retained by RabbitMQ and will be
>> redelivered to some other consumer eventually when your current
>> consumer cancels/dies.
> Careful here - cancelling a consumer with basic.cancel does *not* cause
> unack'ed messages to be requeued/redelivered. For that to happen the
> channel needs to be closed (explicitly, or implicitly via a connection
> closure or termination).
Fair enough. Using Python you would ensure that the related code is
properly enclosed within a context manager. For the case the consumer
dies for whatever reasons: the channel would be closed and the action
taken by the queue as you described it.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
-----END PGP SIGNATURE-----
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 316 bytes
Desc: not available
Url : http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20100506/5a37d3d6/attachment.vcf
More information about the rabbitmq-discuss