We are using worker threads to process messages. So, onMessage() calls
simply return by delegating the processing to the worker thread. Once the
worker thread processes the message, worker thread calls
message.acknowledge(). So, if I set a prefetch buffer of 10, and 9 messages
are getting processed now and 1 finished processing and sent an
acknowledge(), I would expect only 1 message to show up in my prefetch
buffer. But, the prefetch buffer gets filled with next message as soon as
onMessage() completes, not when message.acknowledge() happens. Why is
that??? I tried setting ackMode in CLIENT_ACKNOWLEDGE,
INDIVIDUAL_ACKNOWLEDGE. I even tried session.commit(). Nothing seems to stop
filling up prefetch buffer. Any Ideas??? We don't want to avoid using
receive() or adding multiple consumers by setting prefetchLimit of 1.
--
View this message in context:
http://old.nabble.com/prefetch-buffer-along-with-acknowledgement-mode-tp29292780p29292780.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.