activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Tully <>
Subject Re: Dispatch Policy
Date Fri, 22 Jul 2011 08:19:40 GMT
you may want to use consumer.receive(timeout) on your client and a
prefetch of 0. In this way your client will poll for a single message.
With prefetch of 1, a second message will be cached on the consumer
while the first is pending.

On 21 July 2011 22:30, yousafsajjad <> wrote:
> Hi,
> I am confused with different dispatch policies. There seems to be few
> dispatch policies available in activemq along with bunch of properties that
> can be changed to achieve different purposes.
> RoundRobin dispatch policy is not working for me. My messages are getting
> stuck with the thread that is already busy with working with something
> heavy. What dispatch policy along with with settings you believe would be a
> good solution and why?
> I want such a mechanism that will send the coming message to a free
> consumer. I think I can achieve this using simple dispatch, prefetch limit
> set to 1 and having few threads.
> What do you think? Any suggestions?
> Thanks
> --
> View this message in context:
> Sent from the ActiveMQ - User mailing list archive at


View raw message