Creating a localhost cluster

A localhost cluster is a RabbitMQ cluster where two or more instances of RabbitMQ are configured as a single cluster on the same host.

Actually, this is not very useful in production since it does not offer any scalability or reliability improvement. On the other hand, it is very useful to create a localhost cluster to test configurations on, for example, a development PC.

Getting ready

In order to put this recipe in action we just need RabbitMQ installed and running.

Even if it is not strictly required, we have installed the management plugin as shown in Chapter 3, Managing RabbitMQ. In this way, we need to specify a different web console TCP port for every broker.

How to do it…

In order to create a localhost cluster, we ...

Get RabbitMQ Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.