activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pollotek <>
Subject Unbalanced message dispatching
Date Thu, 02 Jan 2014 22:40:23 GMT
I have a non persistent network of brokers composed of 2 brokers and 2
consumers. Consumers are configured to failover connect to broker1 and
broker2 in that order.

I've noticed that when I redeploy my app, which requires the consumers to be
restarted, one of the consumers CPU goes very high (sometimes it reaches
100%) and stays like that until bounced again and the other one goes very
low doing almost nothing. I interpret this as the brokers dispatching all
messages to one of the consumers only and the other one is not getting any

I can only get the load rebalanced by bouncing both consumers at exactly the
same time. My servers process about 50k messages per minute distributed
across 20 different queues. 

This is my consumer connection factory configuration: 

    <bean id="jmsConnectionFactory"
        <property name="maxConnections" value="8"/>
        <property name="maximumActive" value="500"/>

On the brokers the only destination policy I have is DQL which seems
completely unrelated:

                    <policyEntry queue=">">
                            <individualDeadLetterStrategy queuePrefix="DLQ."
useQueueForQueueMessages="true" />

So the brokers should be using the default Round robin dispatch policy. My
whole system is running on Ubuntu 12.04.3 LTS, Java 1.6.0_32 Hotspot 64 and
ActiveMQ 5.6.

How can I make my brokers dispatch messages more evenly to my two consumers?

It would be handy if JMX exposed metrics included messages dispatched per
consumer server. 

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message