[jboss-user] [JBoss Messaging] - Duplicate message after recovery rollback
do-not-reply at jboss.com
Mon Oct 20 17:02:29 EDT 2008
I run XA transaction which includes read from remote JBM queue and write to the application database (non-XA driver). The steps are the following:
1) Message received and processed (application database update).
2) TM calls prepare on JBM; transaction record is created in JBM_TX table. Remote queue MBean shows MessageCount=1, DeliveringCount=1.
3) Kill JBoss before commit phase and TM log created. Transaction record is still in JBM_TX table; remote queue MBean shows MessageCount=1, DeliveringCount=0.
4) Start JBoss. Message received and processed. Transaction record is still in JBM_TX table and message record in JBM_MSG. Remote queue MBean shows MessageCount=0, DeliveringCount=0.
5) TM recovery calls rollback on remote JMB XAResource (as expected). Transaction record in JBM_TX is deleted, message remains in JBM_MSG. Remote queue MBean shows MessageCount=0, DeliveringCount=0.
6) Restart remote queue (MBean or JBoss): the same message is delivered second time. All JBM tables empty.
My understanding, that if transacted session is used, JMS guarantees that any given message delivered only once.
Any comments will be greatly appreciated.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4183350#4183350
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4183350
More information about the jboss-user