[rabbitmq-discuss] Envelop redeliver question ( clustering ha redelivery question)
mvikasetc at gmail.com
Sun Jul 8 20:32:43 BST 2012
I have setup rabbitmq cluster with 2 nodes and i am using joshdevins
rabbitmq ha client to consume messages - to simulate real scenario of
data processing i have added sleep for 10 seconds before sending ack.
On crashing(stopping) the master node - the connection is re
established with 2nd rabbitmq node However i do received the last un
acknowledged message which was failed to ack due to master node crash.
This is acceptable and expected. To handle this scenario i thought to
use isRedeliver value from envelop but i observed different behavior
than documented about redeliver flag value.
On restarting the node which was down. I see all messages with
redelivered(delivery.getEnvelope().isRedeliver()) as true in my
consumer. The consumer was also restarted after restarting the node.
Why the redelivery value is true when the messages were not even
attempted to ack by consumer.
Is this a bug or am i doing something wrong?
java doc reference : redeliver - true if this is a redelivery
following a failed ack
More information about the rabbitmq-discuss