RoundRobinDispatchPolicy divides uneven ---------------------------------------
Key: AMQ-1006 URL: https://issues.apache.org/activemq/browse/AMQ-1006 Project: ActiveMQ Issue Type: Bug Components: Broker Affects Versions: 4.0.2 Reporter: Holger Bruch Priority: Minor Attachments: RoundRobinDispatchPolicyDivide.patch In case that multiple consumers with different message selectors are registered for the same destination, messages are not evenly divided. To reproduce, register 2 consumers for prio 9, one for prio 4. Of 1000 messages with prio 9 both prio 9 consumers should receive 500. Actually, the first consumer gets 667 messages, the second 333. This is caused by the consumer shifting strategy in the RoundRobinDispatchPolicy which rotates consumers, even if they did not match. The attached file contains a testcase illustrating the behavior and a patch for RoundRobinDispatchPolicy, that shifts the first matching consumer instead of the first. -- 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