Hi,

Is there any way to have messages consumed from a queue but not yet
committed not stored in memory anymore ? Here is a description of what
my application wants to do :

 - Some messages get send to a queue. Let's say each message is S bytes in size.
 - a consumer is set up on this queue, using a transacted session and
a message listener to get the messages.
 - the listener gets called each time a message is ready. It consumes
it. Once every N calls, it commits the session.

I see is that the queue needs a memoryLimit above N*S for this system
to be able to work. If it is set it below that value, I get a deadlock
: New messages can't be dispatched as long as there isn't free memory,
but memory won't be freed until the session gets committed, which
depends on getting new messages...

What I am looking for is a way to lower that memoryLimit below that
N*S threshold, essentially as low as S. Is there a way that memory can
get released as soon as the message gets dispatched? This would of
course imply that in case a rollback is needed, the message gets
fetched from the storage again.

TIA for your help,

Reply via email to