You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Kevin Yaussy (JIRA)" <ji...@apache.org> on 2006/06/26 15:56:51 UTC

[jira] Created: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

ConduitBridge can malfunction when first of a set of consumers goes away
------------------------------------------------------------------------

         Key: AMQ-776
         URL: https://issues.apache.org/activemq/browse/AMQ-776
     Project: ActiveMQ
        Type: Bug

  Components: Broker  
    Versions: 4.0.1    
    Reporter: Kevin Yaussy
    Priority: Critical
 Attachments: ConduitBridge.patch

When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.

+++++++++++++++++++++++
Start Broker A

Start Broker B

Start Consumer 1, connecting to Broker B, consuming FOO

Start Consumer 2, connecting to Broker B, consuming FOO

Start Publisher, connecting to Broker A, publishing FOO

Ctl-C out of Consumer 1

Consumer 2 stops receiving messages
+++++++++++++++++++

Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.

I've attached a patch.  Hope the change is good.


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Kevin Yaussy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQ-776?page=comments#action_37081 ] 
            
Kevin Yaussy commented on AMQ-776:
----------------------------------

Hiram,

I have been very busy with some other items around here, so I've not worked on this for about a month.  I'm planning on downloading the recent 4.0.2 and looking there again.  But, also, it looks like 4.1 is pretty active?  I'll download that and test this scenario there as well.

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch, DemandForwardingBridgeSupport.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Kevin Yaussy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQ-776?page=comments#action_36780 ] 
            
Kevin Yaussy commented on AMQ-776:
----------------------------------

I'll attach a patch file for DemandForwardingBridgeSupport.java which is baselined on the 4.0.1 version.  It includes the logging changes from my other call, which you've already applied to 4.0.2.

When I was analyzing the problem, it looked to me like there was more to the problem than just clearing out the subscription maps (which is what the 4.0.2 code does).  It needed to forward the subscription removal to the broker, which is why my patch calls removeSubscription, which forwards the removal to the broker code, but also removes the entry from the local subscription map.  It did not make any difference whether I cleared the remote subscription map, so that step is not in the patch (but could be for cleanliness).

I've downloaded the current 4.0.2 snapshot, and applied this change (replacing the 4.0.2 version of clearDownSubscriptions).  However, the problem still persists in 4.0.2.  So, given other changes in 4.0.2, the change is not compatible - which is bad.

The first patch for this call, ConduitBridge.patch, is applicable to 4.0.2.

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Reopened: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Hiram Chirino (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/AMQ-776?page=all ]

Hiram Chirino reopened AMQ-776:
-------------------------------

             
This issue looks like it's still not resolved.

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch, DemandForwardingBridgeSupport.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Kevin Yaussy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQ-776?page=comments#action_36535 ] 

Kevin Yaussy commented on AMQ-776:
----------------------------------

I found another scenario, but have not had time to discover whether it is due to problem in ConduitBridge or not.  But, it seems likely:

+++++++++++++++++++++++++++
Start Broker A

Start Publisher, connecting to Broker A, publishing FOO

Start Broker B

Start Consumer, connecting to Broker B, consuming FOO (needs to use failover on connect url, but just connect to Broker B)

kill-9 Broker B

Restart Broker B

Consumer no longer gets FOO
+++++++++++++++++++++++++++++++++

This problem happens regardless of whether the patched ConduitBridge code is used. 

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>          Key: AMQ-776
>          URL: https://issues.apache.org/activemq/browse/AMQ-776
>      Project: ActiveMQ
>         Type: Bug

>   Components: Broker
>     Versions: 4.0.1
>     Reporter: Kevin Yaussy
>     Priority: Critical
>  Attachments: ConduitBridge.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Assigned: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "james strachan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/AMQ-776?page=all ]

james strachan reassigned AMQ-776:
----------------------------------

    Assignee: Rob Davies

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>         Attachments: ConduitBridge.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Rob Davies (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQ-776?page=comments#action_36744 ] 
            
Rob Davies commented on AMQ-776:
--------------------------------

Hi Kevin,

not sure I understood the last comment ? :) - clearDownSubscriptions in DemandForwardingBridgeSupport clears the subscription maps - do you do something different ?

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Resolved: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Rob Davies (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/AMQ-776?page=all ]

Rob Davies resolved AMQ-776.
----------------------------

    Fix Version/s: 4.0.3
       Resolution: Fixed

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Kevin Yaussy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQ-776?page=comments#action_36594 ] 
            
Kevin Yaussy commented on AMQ-776:
----------------------------------

Any reason why "clearDownSubscriptions" in DemandForwardingBridgeSupport is uncoded?  Or perhaps overridden in ConduitBridge?

I've coded an override method in ConduitBridge and this seems to take care of the issue.

Maybe you coded it once, but some test cases failed?

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>            Priority: Critical
>         Attachments: ConduitBridge.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Resolved: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Rob Davies (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/AMQ-776?page=all ]

Rob Davies resolved AMQ-776.
----------------------------

    Fix Version/s: 4.2.0
                       (was: 4.0.3)
       Resolution: Fixed

patch applied for associated issue: http://issues.apache.org/activemq/browse/AMQ-961

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.2.0
>
>         Attachments: ConduitBridge.patch, DemandForwardingBridgeSupport.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Kevin Yaussy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQ-776?page=comments#action_37135 ] 
            
Kevin Yaussy commented on AMQ-776:
----------------------------------

Hiram,

With help from Holger Bruch on AMQ-961, this issue I think can be resolved.  For AMQ 4.0.2, apply the ConduitBridge patch, which fixes the first part of this issue.  Apply Holger's patch from AMQ-961 to DemandForwardingBridgeSupport.  That fixes the issue from AMQ-961, but also the second part of this issue.


> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch, DemandForwardingBridgeSupport.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Kevin Yaussy (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/AMQ-776?page=all ]

Kevin Yaussy updated AMQ-776:
-----------------------------

    Attachment: DemandForwardingBridgeSupport.patch

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch, DemandForwardingBridgeSupport.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (AMQ-776) ConduitBridge can malfunction when first of a set of consumers goes away

Posted by "Kevin Yaussy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQ-776?page=comments#action_36776 ] 
            
Kevin Yaussy commented on AMQ-776:
----------------------------------

Rob,

The code for clearDownSubscriptions in DemandForwardingBridgeSupport.java is not present (empty method) in 4.0.1.  Perhaps you are looking at 4.0.2 or 4.1?  I haven't downloaded those versions yet.

> ConduitBridge can malfunction when first of a set of consumers goes away
> ------------------------------------------------------------------------
>
>                 Key: AMQ-776
>                 URL: https://issues.apache.org/activemq/browse/AMQ-776
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 4.0.1
>            Reporter: Kevin Yaussy
>         Assigned To: Rob Davies
>            Priority: Critical
>             Fix For: 4.0.3
>
>         Attachments: ConduitBridge.patch
>
>
> When the following scenario is followed, any of the subsequent consumers will stop receiving messages.  I've reproduced this using the ConsumerTool, and ProducerTool supplied in the example area of the distribution.
> +++++++++++++++++++++++
> Start Broker A
> Start Broker B
> Start Consumer 1, connecting to Broker B, consuming FOO
> Start Consumer 2, connecting to Broker B, consuming FOO
> Start Publisher, connecting to Broker A, publishing FOO
> Ctl-C out of Consumer 1
> Consumer 2 stops receiving messages
> +++++++++++++++++++
> Seems to me that ConduitBridge is supposed to track all consumers for a given subscription, by way of DemandSubscription.  It is seeding DemandSubscription with the originating consumer, but when subsequent consumers are added, the ConduitBridge::addToAlreadyInterestedConsumers re-adds the original subscriber to the DemandSubscription's map - so the map only ever has the original subscription.
> I've attached a patch.  Hope the change is good.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira