Actually this gets more complex.
There are some situations where sending messages directly if the transaction is not
enlisted in a global tx will give incorrect behaviour.
See this comment from MesagingXAResource:
| //If I commit/rollback the tx, then there is a short period of time between the AS (or
whoever)
| //calling commit on the tx and calling start to enrolling the session in a new tx.
| //If the session has any listeners then in that period, messages can be received
asychronously
| //but we want them to be received in the context of a tx, so we convert.
|
So we have to be very careful here.
AFAICT the only time when it would be valid to directly send messages using an XASession
is if the session had never been enlisted in a global tx.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3968783#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...