Quorum queues provide the queue replication capability to ensure high data availability and security.

Quorum queues can be used to replicate queue data between RabbitMQ nodes, ensuring that queues can still run when a node breaks down.

In Quorum queues messages are written to the disk for Persistence.

Most Commonly 3 Nodes Cluster is Used for Quorum Queue.

  • 1 Leader
  • 2 Followers

When we going to write message to Master (Leader) then it is going to replicate to its followers. Same way when we are going to acknowledge master it will do it to its followers.

When a client (Producer) attempts to read/write to a follower, it is told who the leader is and told to send all writes to that node. The leader will only confirm the write to the client once a quorum of nodes has confirmed they have written the data to disk.

Consistency and Availability

A quorum queue is only available when a majority (quorum) of replicas are available. A quorum queue with a replication factor of three, on a three broker cluster can only tolerate the loss of a single broker. If two brokers go down then the queue becomes unavailable to clients.

Failure tolerance characteristics of clusters of various size can be described in a table:

Example

Creating Quorum Queue

Quorum Queue

Running 3 Node Cluster

By Saineshwar

Microsoft MVP for Developer Technologies | C# Corner MVP | Code project MVP | Senior Technical Lead | Author | Speaker | Love .Net | Full Stack developer | Open source contributor.