You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by xing <xi...@healthalliance.co.nz> on 2019/03/06 03:01:47 UTC

Network of Brokers: cannot forward messages back to the broker from which they came

Create two brokers A and B with mesh network  connection as shown below

Broker A networkConnector
------------------------------------------
<networkConnectors>
    ...
    <networkConnector name="bridgeToB"
                      uri="static:(tcp://brokerB-host:61616)"
     networkTTL=”2”
     decreaseNetworkConsumerPriority="true"
     suppressDuplicateQueueSubscriptions="true" />
  ...
</networkConnectors>
------------------------------------------

------------------------------------------
Broker B networkConnector
------------------------------------------ 
<networkConnectors>
    ...
    <networkConnector name="bridgeToA"
                      uri="static:(tcp://brokerA-host:61616)"
     networkTTL=”2”
     decreaseNetworkConsumerPriority="true"
     suppressDuplicateQueueSubscriptions="true" />
     ...
</networkConnectors>

Steps to produce this problem
1. Send a number of messages (e.g. 100) to broker A
2. create a new consumer connecting to Broker B to consume a message, 100
message were successfully forwarded from  broker A to broker B and one
message was consumed by the consumer, there were 99 pending messages left in
broker B
3. Create another new consumer connected to broker A to receive message, but
no messages were forward from broker B back to broker A, as a result, the
consumer times out and no message was delivered from broker A. connect to B
can still get messages







--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: Network of Brokers: cannot forward messages back to the broker from which they came

Posted by xing <xi...@healthalliance.co.nz>.
Find the solution.

need to add enableAudit="false" in policyEntry



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: Network of Brokers: cannot forward messages back to the broker from which they came

Posted by xing <xi...@healthalliance.co.nz>.
Thanks Tim

Actually I have already included the following configuration as per
document, it didn't work

<policyEntry queue=">" >
     .....
    <networkBridgeFilterFactory>
       <conditionalNetworkBridgeFilterFactory replayWhenNoConsumers="true"/>
     </networkBridgeFilterFactory>
      ....
</policyEntry>


Thanks



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: Network of Brokers: cannot forward messages back to the broker from which they came

Posted by Tim Bain <tb...@alumni.duke.edu>.
Please see the Stuck Messages section of
http://activemq.apache.org/networks-of-brokers.html.

Tim


On Tue, Mar 5, 2019, 10:06 PM xing <xi...@healthalliance.co.nz> wrote:

> The ActiveMQ version is 5.15.2
>
>
>
> --
> Sent from:
> http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html
>

Re: Network of Brokers: cannot forward messages back to the broker from which they came

Posted by xing <xi...@healthalliance.co.nz>.
The ActiveMQ version is 5.15.2



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html