1
votes

I have two questions regarding ActiveMQ.

  1. On my environment, I set up 3 ActiveMQ in 3 servers and share one Database. Is it possible to run the 3 ActiveMQ in the 3 servers to share the same database? I tried to set it up. However, it looks like 3 brokers cannot share the same database. Is it correct?
  2. Also, I did some Failover testing, it looks like the ActiveMQ cannot guarantee the message order. e.g. I set up the 3 ActiveMQ into ServerA,ServerB and ServerC. And then, I published MessageA,MessageB into ServerA and published MessageC into ServerB. The ServerA ServerB and ServerC had been set up as Failover servers. When I shut down ServerA, the only MessageC can be consumed. However, the consumed message order should be MessageA,MessageB and MessageC. I need to keep this message order even through the ServerA is down. Is it possible to configure ActiveMQ to guarantee the message order for Failover?

Thank you!

1

1 Answers

0
votes
  1. You can set all 3 to the same DB. They will act like a master-slave failover. Only one instance will run and other two will be waiting for a lock from the DB to takeover.

  2. If you follow #1, it will guarantee the order, but you'll be using one server at a time (and the centralized DB as storage)