activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Tully <gary.tu...@gmail.com>
Subject Re: Virtual Topic and missed messages gone missing with selectorAware=true
Date Mon, 01 Nov 2010 09:32:55 GMT
Message expiry may help in the short term, set a time to live on the
messages such that the built up unmatched messages expire and are
removed.

On 1 November 2010 09:20, Maciej Rakowicz <maciek@homeaway.co.uk> wrote:
> All,
>
> amq 5.4.0. jdk 1.6
>
> Scenario:
> broker persistence=true, selectorAware=false
> Virtual Topic with say one queue. There is a consumer A connected to that
> queue with a selector. All works fine. Consumer A dies, messages pile up,
> consumer A starts back up, missed messages are redelivered. You can easily
> verify that queue receives all posted messages while consumer's down.
> Now, adding consumer B, since selectorAware=false and consumer B uses an
> exclusive selector messages sent to consumer A are not consumed by consumer
> B. All good save the fact that all unmatched messages end up polluting
> consumer's B queue. All according to the documentation.
> Flipping selectorAware to true solves one problem but introduces another
> (way more important in my setup). Unmatched messages won't pile up on
> consumer's B queue which is fine. However, if consumer A dies they are not
> sent to consumer's A queue (disappearing after reaching the topic - I dunno
> where they go) hence disabling any missed message delivery on consumer's A
> startup.
>
> I there any way around it? I really need to handle all missed messages with
> no exception. At the same time I cannot allow stacking up messages in each
> and every queue although they are not matched.
>
> Btw. I do not have a list of consumers in advance, the subscription is fully
> dynamic, although since broker runs persistence, once subscribed I do have
> an idea of who's subscribed even if connection is currently down.
>
> I would appreciate any hints.
>
> mac



-- 
http://blog.garytully.com
http://fusesource.com

Mime
View raw message