activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <>
Subject Re: Sending messages to topic with no consumers at all( with message TTL set on)
Date Mon, 22 Jan 2007 16:04:43 GMT
On 1/22/07, leonardinius <> wrote:
> Hi and sorry for my poor English skills,
> I have reached some problem.  I have to post some message to some
> topic(dynamically created by request), which do not have any subscribers at
> all. I MUST HAVE to support message TTL (time to live) feature, among other
> I MUST HAVE to support another facility: at any time any could subscribe to
> this topic and SHOULD receive all the messages sent.
> -I-]
> If only one or more subscribers could be (already KNOWN), I could create
> durable subscriptions for them, then close them, then (on reqyuaet) open and
> consume, then unsubscribe. The problem is:
> a) I don't know subscribers and their count
> b) All the subscribers( even subscribed to this topic after it creation
> time, but before TTL ends up) SHOULD receive this message.
> -II-]
> I am thinking about <retroactive> feature usage, but as far I understand, it
> stores ALL the messages for the topic, so any DURABLE subscription to this
> topic would get ALL the messages, not just the messages sent to topic after
> the subscription made + those with TTL.
> Thanks a lot for any comments and recomendations!

I'd recommend using <retroactive> and just implementing your own strategy

and implement your own subscription recovery policy...

or you could go with the idea of using a single persistent
subscription using a wildcard. e.g. to FOO.> then all your generated
topics begin with FOO..> such as FOO.A or FOO.A.B.C.WHATNOT

The only thing is I don't think we've yet implemented retroactive for
durable subscriptions - so the first idea is probably the easiest
(unless you wanna patch the code to support retroactive on persistent



View raw message