users@glassfish.java.net

Re: Delivery of JMS message in case of distributed transaction

From: Marina Vatkina <Marina.Vatkina_at_Sun.COM>
Date: Mon, 22 Jun 2009 13:45:49 -0700

LAO (last-agent-optimization).commit() happens at the end of prepare() phase, so
that the result of it can be used to commit or rollback the XA resources.

Regards,
-marina

glassfish_at_javadesktop.org wrote:
> Our JPA implementation is Hibernate 3. The synchronization works and the dirty entites are flushed before the 2PC starts - I suppose that it's using JTA's synchronization facility under the hood.
>
> I didn't thought about the last-agent-optimization. However, based on my understanding, JMS should be the one to be non-XA. In this case JMS will always be the last participant and this forces the database commit to happen first.
>
> I checked again the JTA, JCA and JMS specs briefly, and I couldn't find any information about how the transaction manager is supposed to order/prioritize the RM enlisted in the distributed transaction.
> * Does the TM prepare and commit the RM in the same order they were enlisted?
> * Is there some settings somewhere where we can assign a priority to the RM ?
> [Message sent by forum member 'ewernli' (ewernli)]
>
> http://forums.java.net/jive/thread.jspa?messageID=352172
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>