activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Elmo <>
Subject Glassfish 3.1.2, ActiveMQ 5.9.0, MDB: Long lasting Message blocks other Messages
Date Mon, 11 May 2015 12:50:14 GMT

I've got a MessageDrivenBean, running in Glassfish 3.1.2, listening to an
ActiveMQ 5.9.0 Queue. When a Message is processed and needing a long time,
other messages wait for processing.

Test scenario: Sending a big message (needing approx. 30 minutes to process)
and 250 small messages while the first is still in progress. Then 62 of the
small messages wait for the big one before they get processed.

The MessageDrivenBean has a bean-pool size of 4, in this test I did not use
a prefetch limit. Additional tests with various settings (e.g.
?jms.prefetchPolicy.queuePrefetch=20 or ...=2, threadpool max queue size 2)
did not solve the problem, there are always small messages waiting for the
big one.

My question is: does anybody know a way how to configure the MDB, ActiveMQ
and/or glassfish to avoid this problem? Or is this a typical scenario for
polling, e.g. by a TimerBean? I know, alternatively I could work with two
queues and two MDB (one for big and one for smaller messages), but this
would mean that some of my other JMS communication parties would need to be

Thank you in advance and best regards, Marc

View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message