> I would like to switch it to JTS in order to get XA support for database activity and JMS message creation in one atomic transaction.
You don't need JTS for that unless you are using more than one JBoss instance. If the database and JMS are communicated to from the same JBoss server then JTA is sufficient.
No JTS is currently available for AS 4.2, as it's got a new ORB that we don't yet support. I hope to have the first JBossTS 4.4 beta out shortly to address this.
> You don't need JTS for that unless you are using more than one JBoss instance.
Then I must be doing something wrong or have a bad misconception.
I have a transaction in which I write some rows to the database and send a JMS message. Sometimes I am getting a race condition where the MDB that is recieving the message fires up and looks in the database and can't find the new rows; the original transaction is not committed yet. If I step through in debug mode, or make the MDB sleep for a couple seconds before hitting the database, the race condition goes away.
I thought the whole point of having JMS participate in a transaction was so that the message would not be placed on the queue (and therefore not be consumed by the receiving MDB) until the transaction was complete?
(BTW, my JMS provider is JBossMQ, which is the default configured for JBoss AS 4.2.0.GA. would switching to JBoss Messaging make a difference?)