activemq-artemis/examples/features/broker-connection/disaster-recovery
Clebert Suconic b8c64590f9 [maven-release-plugin] prepare for next development iteration 2021-08-09 11:58:28 -04:00
..
src/main ARTEMIS-3243 Implementing dual mirror with Broker Connections 2021-08-03 16:50:43 -04:00
pom.xml [maven-release-plugin] prepare for next development iteration 2021-08-09 11:58:28 -04:00
readme.md ARTEMIS-3243 Implementing dual mirror with Broker Connections 2021-08-03 16:50:43 -04:00

readme.md

AMQP Broker Disaster Recovery

To run the example, simply type mvn verify from this directory, or mvn -PnoServer verify if you want to create and start the broker manually.

On this broker you will have two brokers connected to each other.

This broker configure two servers:

  • server0
  • server1

Each broker has a broker connection towards the other broker, with a mirror tag configured:

 <broker-connections>
    <amqp-connection uri="tcp://localhost:5661" name="otherBroker" retry-interval="1000">
       <mirror/>
    </amqp-connection>
</broker-connections>

Watever happens in server0 is replicated to server1 and vice versa.

In case you want to play this in real life, all you have to do is to move your consumers and producers from one broker towards the other broker.