activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Bain <tb...@alumni.duke.edu>
Subject Re: Howto avoid stranded messages in a network of brokers?
Date Wed, 25 Apr 2018 12:29:00 GMT
See the Stuck Messages section of
http://activemq.apache.org/networks-of-brokers.html for an explanation of
the problem and its solution.

Tim

On Wed, Apr 25, 2018, 12:15 AM Dolk <bjorn.dolk@linkon.se> wrote:

> AMQ 5.15.3
>
> We have configured AMQ with two brokers clustering via static uri's
> ---------------
> BrokerA config
> ---------------
> ...
> <networkConnector name="dmz-cluster" userName="${activemq.username}"
> password="${activemq.password}" uri="static:(tcp://brokerB:61616)"  />
> ...
> <destinations>
>         <queue physicalName="DLQ" />
>         <queue physicalName="Test.Queue" />
> </destinations>
> ...
>
> --------------
> BrokerB config
> --------------
> ...
> <networkConnector name="dmz-cluster" userName="${activemq.username}"
> password="${activemq.password}" uri="static(tcp://brokerA:61616)"  />
> ...
> <destinations>
>         <queue physicalName="DLQ" />
>         <queue physicalName="Test.Queue" />
> </destinations>
> ...
>
>
> Generally this works great, but there are an edgecase which gives us
> problems.
>
> 1. Push 10 messages to BrokerA:Test.Queue
> 2. Connect a consumer to BrokerB:Test.Queue and pop a message
> 3. Dissconnect consumer
> At this stage the messages flow over to BrokerB:Test.Queue so we end up
> with
> 9 messages on BrokerB:Test.Queue
>
> 4. Connect a consumer to BrokerA:Test.Queue
> 5. Try to pop a message
>
> The consumer will not get any message AMQ will refuse to reroute the 9
> already forwarded on BrokerB:Test.Queue back to BrokerA:Test.Queue
>
> This is an edgecase but I can see it happening during poor networking
> conditions or rolling updates for a single consumer using
> failover:(brokerA;brokerB) config.
> I have tested to played around with the networkTTL, but to no avail.
>
> I am assuming this is somehow by design. Can it be configured differently
> or
> do we have to find other ways to work around this possible scenario?
>
>
>
>
>
> --
> Sent from:
> http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html
>

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