Quantcast
Channel: Apache Timeline
Viewing all articles
Browse latest Browse all 5648

Delayed messages not delivered when master goes down.

$
0
0
Here is my setup

I have a master/slave (apache-activemq-5.8.0) configuration using MySql
database as a shared storage.

Next a client connects to the current master broker via
failover:(tcp://host1:61616,tcp://int-host2:61616)?randomize=false and posts
a message with a delayed delivery to a queue.

Delay is set via this

message.setLongProperty(ScheduledMessage.AMQ_SCHEDULED_DELAY, delay);

Under normal operation delayed messages are delivered to consumers after the
correct amount of delay.

BUT
If the current master broker, where the client connected to and posted
delayed messages, goes down and a slave is selected master those delayed
messages will never be delivered. I have looked at the code and it seems
delayed messages are stored locally using classes from
org.apache.activemq.store.kahadb.scheduler package which is dealing with
local disk only.

Thanks all,
-Lu

Viewing all articles
Browse latest Browse all 5648

Trending Articles