activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From MARollins <mark.roll...@poz.im>
Subject Prefetch problem
Date Fri, 05 Nov 2010 11:26:54 GMT

Hi,

I'm running ActiveMQ 5.3. I have a single consumer which receives (large -
up to 4MB) messages from a queue and after some checking, emails them. The
problem I have is that the prefetch doesn't seem to be working. 

Because of the size of the messages and client memory limitations, I have
set the prefetch to 1, so that just a single message is dispatched at a time
(or so I thought).

I did this using the following...

Queue.Name?jms.prefetchPolicy.queuePrefetch=1

in the call to session.createConsumer.

When I debug the client aplication and look at the console I can see ...

562 enqueued (as expected), 
0 dequeued (as expected)
562 dispatched,
562 dispatched queue

(I have a breakpoint in the messageHandler where I have stopped on receipt
of the first message). 

I was expecting to see just 1 message dispatched. If I then let the
application run, it very quickly runs out of memory.

Any help would be appreciated.

Thanks




-- 
View this message in context: http://activemq.2283324.n4.nabble.com/Prefetch-problem-tp3028494p3028494.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Mime
View raw message