[ 
https://issues.apache.org/jira/browse/ARTEMIS-2531?focusedWorklogId=334304&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-334304
 ]

ASF GitHub Bot logged work on ARTEMIS-2531:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 25/Oct/19 18:41
            Start Date: 25/Oct/19 18:41
    Worklog Time Spent: 10m 
      Work Description: michaelandrepearce commented on pull request #2872: 
ARTEMIS-2531: Fix filter in FederatedQueue to prevent infinite consumer 
creation in a circular or bidrectional setup
URL: https://github.com/apache/activemq-artemis/pull/2872#discussion_r339188731
 
 

 ##########
 File path: 
artemis-server/src/main/java/org/apache/activemq/artemis/core/server/federation/queue/FederatedQueue.java
 ##########
 @@ -63,7 +63,7 @@ public FederatedQueue(Federation federation, 
FederationQueuePolicyConfiguration
       Objects.requireNonNull(config.getName());
       this.config = config;
       this.priorityAdjustment = federationUpstream.getPriorityAdjustment() + 
(config.getPriorityAdjustment() == null ? -1 : config.getPriorityAdjustment());
-      String metaDataFilterString = config.isIncludeFederated() ? null : 
FederatedQueueConsumer.FEDERATION_NAME +  " IS NOT NULL";
+      String metaDataFilterString = config.isIncludeFederated() ? null : 
"hyphenated_props:" + FederatedQueueConsumer.FEDERATION_NAME +  " IS NOT NULL";
 
 Review comment:
   It is meant to be circular in a directional setup, if theres a local 
consumer messages wont go back but should a message move to a broker and then 
consumer go then message should return back to first broker if there is one 
there
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 334304)
    Time Spent: 50m  (was: 40m)

> FederatedQueue has invalid filter string leading to an infinite consumer loop
> -----------------------------------------------------------------------------
>
>                 Key: ARTEMIS-2531
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-2531
>             Project: ActiveMQ Artemis
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 2.10.1
>            Reporter: Christopher L. Shannon
>            Assignee: Christopher L. Shannon
>            Priority: Major
>             Fix For: 2.11.0
>
>          Time Spent: 50m
>  Remaining Estimate: 0h
>
> FederatedQueue by default is supposed to set a metadataFilter to will exclude 
> reacting to federated consumers so a loop isn't created.  Unfortunately the 
> filter does not work because there is a hyphen in the name so it gets 
> ignored.  The property needs to be prefixed with "hyphenated_props:" for the 
> filter to work.  Currently an infinite loop and consumers will be rapidly 
> created until crashing the broker unless the filter is fixed (if using by 
> directional federated queues)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to