Compare approaches, and decide how you will connect RabbitMQ brokers on more than one machine. The options include clustering, federation, and shoveling. It is possible to mix approaches. Typically you use clustering for high availability and increased throughput, with machines in a single location. You use federation or shoveling to link brokers across the Internet for pub/sub messaging. The two approaches are similar; shoveling provides more control.
Create and run
cluster commands. Scripts show how
to set up, start, restart, add nodes to, and remove nodes from
Auto-configure a cluster by using a default cluster config file. Under "Clustering Transcripts," see "Autoconfiguration of a cluster." This approach is commonly used to automatically configure nodes to join a common cluster. The same configuration can be set on all nodes. Use of the cluster command overrides this approach.
Learn what the federation plugin does, when to use it, how to configure it. To configure the plugin, under "Federation Plugin," see the "Implementation," "Getting Started," and "Configuration" sections.
Create a mirrored queue. Under "Highly Available Queues," see "Creating a Mirrored Queue." Configure queues to be mirrored on other nodes within a RabbitMQ cluster. Should one node of a cluster fail, the queue can automatically switch to one of the mirrors and continue to operate, with no loss of service.