2009/6/22 lzr <jsw...@163.com>:
> Try this way:
>
> Three brokers: b1, b2 and b3; with Queue named q1;
> Config networkConnectors from b1 to b2 and b3;
> For the Queue q1, run consumer application on b2 and b3; The messages put 
> into q1 will be dispatched to b2 and b3 in same weight.
>
> I tried this configuration and found it worked well.

This is a network of brokers:

http://activemq.apache.org/networks-of-brokers.html

In a network of brokers, messages are not load balanced across the
brokers. However, by default, ActiveMQ uses a round robin dispatch
policy so that active consumers on a destination get an equal
distribution of messages. Messages are distributed across the brokers
based on demand from active consumers on q1 on each broker. But note
that if there are no consumers on q1 on a given broker, messages will
not be distributed there.

Additionally, each consumer's prefetch limit will play a part in
message distribution as well:

http://activemq.apache.org/what-is-the-prefetch-limit-for.html

Bruce
-- 
perl -e 'print 
unpack("u30","D0G)u8...@4vyy9&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'

ActiveMQ in Action: http://bit.ly/2je6cQ
Blog: http://bruceblog.org/
Twitter: http://twitter.com/brucesnyder

Reply via email to