activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From justinunger <justinun...@gmail.com>
Subject Multiple Consumers/Single queue
Date Sat, 03 Mar 2007 00:37:55 GMT

I'm having trouble getting load balancing to work across multiple consumers
on a single queue. 

I've read all the docs I could find on the website regarding prefetch
values, async dispatch and round robin dispatch models, but I still can't
get it to work. 

And yeah, I found this page, and tried setting the prefetch value to 1: 

http://activemq.apache.org/i-do-not-receive-messages-in-my-second-consumer.html

The issue I'm having is described exactly on that page. 

I have a bunch of messages sitting in a q. 

I start up a consumer, and he starts processing messages. I've got the
consumer in CLIENT_ACK mode, and he takes about 3-5 seconds to process a
message (simulated processing delay), then he acks it. 

I startup another consumer, to see if he can pick up the slack, but he never
gets any messages, even with both consumer's prefetch values set to 1. 

If I startup both consumers BEFORE there are any messages in the queue,
everything works dandy. 

Trying to add consumers dynamically is where I'm running into problems.

Version is: ActiveMQ 4.1.0-incubator JMS Message Broker 

Any suggestions, or workarounds or other offers of help will be greately
appreciated. 

Thanks
-- 
View this message in context: http://www.nabble.com/Multiple-Consumers-Single-queue-tf3336849s2354.html#a9280295
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message