[rabbitmq-discuss] Re-subscribing to a queue in a cluster

Emile Joubert emile at rabbitmq.com
Mon Oct 8 12:23:37 BST 2012


Hi Adam,

On 05/10/12 00:13, Adam Brightwell wrote:
> 1. Create new consumer and call basicConsume on the original channel.
> 2. Close original channel, recreate channel and call basicConsume with the
> new channel.
> 3. Close the original channel, close the original Connection.  Reconnect,
> recreate channel, call basicConsume with the new channel.

All three options should work, but it is not necessary to re-establish a
new consumer, channel or connection unless directly connected to the
failing node and therefore all options do more work than necessary. The
only required action is to resubscribe the existing consumer (and that
consumer must be prepared to receive duplicate messages).

> OR they will be consumed and unacknowledged. In the latter case, they
> are not being processed by my consumer or at least not making it to
> the "handleDelivery()" method.

So messages are consumed without acknowledgement, but don't make it to
the handleDelivery method? Can you explain what you mean by that?

Also, what version of RabbitMQ are you using? You are advised to use the
latest version.


-Emile




More information about the rabbitmq-discuss mailing list