-
1. Re: Using CLIENT_ACKNOWLEDGE does not seem to work
adrian.brock Apr 20, 2004 11:15 AM (in response to mayobria)Works fine for me:
http://jboss.org/wiki/Wiki.jsp?page=ClientAckExample -
2. Re: Using CLIENT_ACKNOWLEDGE does not seem to work
mayobria Apr 20, 2004 1:07 PM (in response to mayobria)Adrian,
Thank you for the example, I have it working now.
Let me ask a final question regarding JMS and CLIENT_ACKNOWLEDGE rooted in the machanics of JMS rather than specifically with JBoss's implementation.
Let us say we have two MDB listening to the same queue. The message gets delivered to the first MDB, but this MDB does not acknowledge the message. Does the second MDB need to call the session.recover method in order to be able to pick-up this unacknowledged message?
Also, from a timing perspective, what triggers a message to be determined re-deliverable? For example, I may want to have a message delivered to a MDB, perform some operations that may take a few seconds or a minute, and then depending on the success of the operations acknowledge the message or leave it unacknowledged for a different MDB to fetch or for this same MDB to fetch at a near future time.
Regards,
-Brian -
3. Re: Using CLIENT_ACKNOWLEDGE does not seem to work
adrian.brock Apr 21, 2004 9:56 AM (in response to mayobria)Each MDB gets their own session (which you don't have access to anyway).
If you don't acknowledge a message, it will be marked redelivered the next
time it is delivered. This could also happen due to network/client/server failure
or transaction rollback, not just client acknowledge.
Regards,
Adrian