You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by jonb <jb...@solekai.com> on 2014/04/04 08:22:28 UTC

topic performance in cluster

I have a network of 10 brokers which consists of 5 (each on their own
machine) which each post about 1,000 object messages per second to a topic
(for a total of 5,000 messages per second).  There are 5 other machines each
running a broker in the network of brokers which all consume from this same
topic.  I've maxed out the prefetch and have the following settings on the
consumers' ActiveMQConnectionFactory:

<property name="copyMessageOnSend" value="false" />
<property name="useCompression" value="false" />
<property name="disableTimeStampsByDefault" value="false" />
<property name="optimizeAcknowledge" value="true"/>
<property name="optimizedMessageDispatch" value="true"/>
<property name="useAsyncSend" value="true" />
<property name="dispatchAsync" value="true" />

As message traffic gets into the thousands, the brokers complain that the
topic consumers are slow and that messages are being sent to the DLQ.  The
problem is, I've reduced my consumers to doing nothing more than taking the
message off the topic so they should be lighting fast.  I setup the
consumers to consume from the topic using this Camel route:

<route>     
    <from
uri="activemq:topic:abort.topic?destination.consumer.prefetchSize=65535"/>
    <to uri="bean:abortProcessor?method=abort" />
</route>   

Is there either some other way to broadcast messages to the consuming
machines that won't drop messages or does anyone have any configuration
suggestions?  I've spent time researching and trying different config
options to no avail.  Is this too big a broker network for this message load
with topics?  I send much higher message rates to queues in this network
with no issues.

Thanks in advance for any insight on this.



--
View this message in context: http://activemq.2283324.n4.nabble.com/topic-performance-in-cluster-tp4680057.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: topic performance in cluster

Posted by artnaseef <ar...@artnaseef.com>.
How are consumers and producers distributed?  Also, how about the
conduitSubscriptions setting on the network connector?

If conduit subscriptions is false, every consumer added to the network leads
to a cross-network consumer from that broker to all the broker's peers; and
each broker then propogates the subscription to its peers - that's how
dynamic routing works in ActiveMQ.

One way to see this is to look at the number of consumers registered on the
Topic for each broker.

Also keep in mind that each separate Topic subscription gets a copy of the
message.  So, one message going to 1000 Topic subscriptions results in 1000
copies of the message.  Try enabling conduitSubscriptions on the network
connector so only 1 copy of a message crosses between any two brokers:

http://activemq.apache.org/networks-of-brokers.html
conduitSubscriptions="true"




--
View this message in context: http://activemq.2283324.n4.nabble.com/topic-performance-in-cluster-tp4680057p4680086.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: topic performance in cluster

Posted by jonb <jb...@solekai.com>.
I should also add that the objects I am sending to the topic are pretty
small.  They contain a couple 10-20 bytes strings and an integer.



--
View this message in context: http://activemq.2283324.n4.nabble.com/topic-performance-in-cluster-tp4680057p4680058.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.