0
votes

I have created Rabbitmq autocluster with 3 Pods in Kubernetes according to public repository: https://github.com/kuberstack/kubernetes-rabbitmq-autocluster

Messages in queue don't survive Pod restarts in the following basic scenario:

  1. Create durable queue "test"
  2. Send message to queue "test"
  3. Wait 10 minutes and delete pod 1.
  4. Wait 10 minutes and delete pod 2.
  5. Wait 10 minutes and delete pod 3.
  6. List queues.

After deleting all 3 pods, queue "test" always doesn't exist. After each pod deletion, cluster is working properly, I can send and receive new messages.

It looks like Rabbitmq doesn't replicate existent messages to new pods. How can I force Rabbitmq to share all messages with new pods?

Many Thanks,

RabbitMq Startup Logs: Log file

1

1 Answers

1
votes

You need to verify if the queues have their contents mirrored accross the cluster.

RMQ allows administrator to create policies applying to some/all queues, so that the messages contained inside are replicated. Otherwise one message is stored on only one broker, what makes it unavailable if that broker goes down.

The policy description is present at https://www.rabbitmq.com/ha.html