[rabbitmq-discuss] Workaround for basic reject...

Arun Suresh arun.suresh at gmail.com
Sun Jun 7 07:31:46 BST 2009


Hello,

We are currently evaluating rabbitMQ for message passing between distributed
nodes. We have a scenario where we could like to restrict the number of
messages sent to a consume...
>From the documentation i understand that using 'basic.qos' is the way to go
(yes.. we are playing around with the snapshot 1.6 version).

Now assuming we set the prefetch size to lets say 5 for a channel,
everything works fine until the consumer encounters an error while
processing a message.. in which case i would ideally like to have the
consumer send a 'basic.reject', so that the same message may be sent to
another consumer... I then realized that rabbitMQ doesnt support
'basic.reject' and the prescribed way of handling this situation is to close
the channel, which will lead to all un-acked message being resent...

This unfortunately means that if consumer encouters an error on 1 message, I
would not be able to close the Channel immediately.. as there are still 4
messages outstanding... which means i would have to wait for all the other
messages to finish processing before i can send all the successfull acks and
then close th channel... during which time, i wont be able to accept anymore
messages...

I was wondering if anyone might be able to enlighten me with a better way of
doing things..

TIA
-Arun
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20090607/45124a94/attachment.htm 


More information about the rabbitmq-discuss mailing list