activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arjen van der Meijden <>
Subject Consumers newer than messages don't receive messages from queues
Date Mon, 08 Jun 2009 13:40:03 GMT
Hello list,

In a somewhat complicated set of consumption-processing, I have three 
queues. One to indicate a new job, which is consumed by a single 
long-running consumer that sends messages to a second queue.
That second queue is consumed by four consumers that kill themselves 
after having processed a (few) message(s). After each message from the 
second queue is processed, they're send to a third queue which has two 
similar consumers.
As soon as such a consumer exits, a control process starts a new 
consumer, to have a fixed amount of consumers.

The jobs for the initial queue are issued in batches, so there can be a 
burst of about 150 messages, resulting in a burst in the second queue.

As soon as those second-queue-consumers exit however, they don't consume 
much messages. Most of the time it seems that only one is actually doing 
any work and the other three are idle, even if the queue has more than 
100 messages. The same holds for the third-queue-consumers.

It seems to have to do with the fact that those consumers actually 
subscribe to the queue after the messages have been produced. Obviously, 
I want them to start consuming a message as soon as they connect.

All message production and consumption is via Stomp in PHP and the 
ActiveMQ is a 5.2.0-version with mostly a default configuration. I have 
tried to see if subscribing using the headers 'activemq.retroactive' and 
'activemq.dispatchAsync' set to 'true' make any difference, but that 
doesn't seem to do anything.

Anyone knows what's going on and how to fix it?

Best regards,


View raw message