[jboss-dev-forums] [Design of Messaging on JBoss (Messaging/JBoss)] - Re: Branch 1_0_XARecovery

timfox do-not-reply at jboss.com
Fri Dec 8 09:03:54 EST 2006


To re-iterate from my previous post:

What you want to do is basically this:

for the acks:

select message_id from jms_message_reference where transaction_id=? and state ="+"

this gives you all the message ids you want to load

then call persistenceManager.getMessages(List ids) to get the actual messages for those ids.

Then call messageStore.reference(Message m) for each of those messages - this will give you a reference for each of the messages.

Once you have your references you can call channel.handle(ref, tx) to replay them through the channel.

(This will create any callbacks).

A similar procedure applies for acks, except the query to get them is different:

select message_id from jms_message_reference where transaction_id=? and state ="-" 

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

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



More information about the jboss-dev-forums mailing list