Chapter 4. Clustering

So far, we have been dealing with a single RabbitMQ instance, thus demonstrating the various capabilities of the message broker. However RabbitMQ provides a built-in clustering mechanism that can be used in a variety of scenarios related to large scale production deployments of RabbitMQ.

Topics covered in the chapter:

  • Benefits of clustering
  • Clustering support in RabbitMQ
  • A case study on scaling the CSN

Benefits of clustering

So far we have discussed how to use a single RabbitMQ instance for handling various types of message. However, in many production scenarios the number of messages that needs to be processed may increase rapidly over time that this should not impact the time required to process a single message – now we have a problem. To resolve it we need to be able to scale our RabbitMQ server deployment. RabbitMQ clustering support provides a mechanism for horizontally scaling RabbitMQ instances. This essentially means that multiple RabbitMQs can be configured to work as a single logical unit in the form of a clustered message broker.

This provides the means to distribute workloads among instances in a cluster, link clients to different instances in a cluster (thus distributing the number of clients linked to a single instance), or even establish high availability of the messaging broker:

Benefits of clustering
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.137.163.197