[
https://issues.apache.org/jira/browse/ARTEMIS-4911?focusedWorklogId=992064&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-992064
]
ASF GitHub Bot logged work on ARTEMIS-4911:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 17/Nov/25 15:41
Start Date: 17/Nov/25 15:41
Worklog Time Spent: 10m
Work Description: gemmellr commented on code in PR #6054:
URL: https://github.com/apache/activemq-artemis/pull/6054#discussion_r2534576219
##########
artemis-server/src/main/java/org/apache/activemq/artemis/core/postoffice/impl/PostOfficeImpl.java:
##########
@@ -1306,7 +1306,7 @@ Bindings simpleRoute(SimpleString address, RoutingContext
context, Message messa
}
if (bindings != null) {
bindings.route(message, context);
- if (addressInfo != null) {
+ if (addressInfo != null && context.getQueueCount() > 0) {
Review Comment:
Would it makes sense for simpleRoute to return null in this case, actually
holding to its previously-implied contract, rather than return the non-null
bindings and then requiring the caller to also know to check the Context (your
other change above) like this does?
Issue Time Tracking
-------------------
Worklog Id: (was: 992064)
Time Spent: 20m (was: 10m)
> Routed message count increases when message was rejected by filters
> -------------------------------------------------------------------
>
> Key: ARTEMIS-4911
> URL: https://issues.apache.org/jira/browse/ARTEMIS-4911
> Project: ActiveMQ Artemis
> Issue Type: Bug
> Components: Broker
> Affects Versions: 2.35.0
> Reporter: Aleksandr Milovidov
> Priority: Minor
> Labels: pull-request-available
> Time Spent: 20m
> Remaining Estimate: 0h
>
> When a message is sent to an address which has multicast queues with filters,
> and message properties do not match any of the filters, the message is
> discarded, but routed message count increases, and unrouted message count
> does not change.
>
> Steps to reproduce:
> # Create a new Artemis instance.
> # Create address {{TEST}} with multicast routing.
> # Create a multicast queue {{TEST.FILTER}} with filter e.g. {{key='value'}}
> on this address.
> # Send a multicast test message:
> {noformat}
> artemis producer --user=admin --password=admin --url=tcp://localhost:61616
> --message-count=1 --destination=topic://TEST{noformat}
> The message is not delivered to any queue, but the routed message count of
> the address is incremented.
> It also happens when sending a message to FQQN
> {{destination=topic://TEST::TEST.FILTER}}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact