activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Bain <>
Subject Re: ActiveMQ 5.4.14 durable topic since start up
Date Tue, 18 Apr 2017 03:46:52 GMT
To the best of my knowledge, it's not possible in ActiveMQ to guarantee
that the broker will deliver all messages in a topic including the ones
before the first consumer joins the topic.  Unlike some other message
brokers such as Kafka and Kinesis, ActiveMQ's design is to delete messages
once they have been consumed by all consumers, which means that there's
generally no reason to keep messages when there are no consumers, nor even
to keep messages that have been delivered to all the current consumers.

With that said, it might be possible to do what you want using a
combination of a subscription recovery policy
<> and retroactive
consumers <>, but I've
never used either one so you'd have to try them to see whether they
actually created the behavior you're looking for.

If you have a finite, well-known list of durable consumers on the topic, it
might be possible to script the creation of the durable subscriptions (i.e.
connect and then immediately disconnect using the client ID that each
consumer will be using) immediately after broker startup (for example, by
tying into the activemq start/restart script), but that only works if you
know which subscriptions to create.


On Apr 14, 2017 2:34 PM, "vladimiri" <> wrote:

Hello, just want to ask for advice on durable subscriptions.

Here is the case:
I do have a lot of message producers for a topic and I want the topic to be
persistent and durable. But the problem in that all messages sent to topic
_before_ first durable consumer starts is treated as non-persistent and
non-durable and will get lost after broker restart.

I tried to configure destinations in broker.xml but it seems It's not the
right place.

I want topic to be durable/persistent before any subscriber starts.

Thank you for your help.

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message