[jboss-user] [JBoss Messaging] - Re: Duplicate message after recovery rollback

timfox do-not-reply at jboss.com
Tue Oct 21 03:17:56 EDT 2008

"szhigunov" wrote : 
  | My understanding, that if transacted session is used, JMS guarantees that any given message delivered only once. 

Not quite.

If you consume a message in a tx, *and that tx is committed* then the message is guaranteed to never be delivered again. But in your case the tx is never committed, it is rolled back. Rollback causes redelivery (see JMS spec).

It's the recovery manager (I assume you're using JBoss TS), not JBM that decides to commit or rollback. In this case it decides to rollback. Most probably another transaction branch in the same XA transaction failed to prepare (the database update) so this would be correct behaviour.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4183393#4183393

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4183393

More information about the jboss-user mailing list