I'll try with a shorter answer because long ones can be boring to read.
I said that I sort of understood the reason behind the change: "session =
conn.createSession(*false-->true*, Session.AUTO_ACKNOWLEDGE);", although
that change does not seem to affect Bitronix (which works with both).
What I don't get is why (in my sample) *you gave up using the XA ActiveMQ
driver*, in favor of the non-XA one, in a situation where 3 devices need to
participate in a *distributed transaction*.
I though that using XA Drivers for all the devices participating in an XA
transaction was mandatory and that it was not possible to mix XA and non-XA.
I also thought the real problem to be solved was "*how do I make Tomee's
transaction manager aware of my ActiveMQ !!XA!! driver?*".
If I don't misunderstand things, with your proposed solution you just went
back to the known way of configuring Tomee's TM with *non-XA* ActiveMQ
driver which seems to work with the sample with 2 devices, but that I did
not see working with 3 devices. And in both cases I get recurrent WARNINGs
in the log.
Or maybe I am completely OFF TRACK and with your approach:
/
<Resource id="Default JMS Resource Adapter"
type="ActiveMQResourceAdapter">
BrokerXmlConfig =
ServerUrl =
tcp://localhost:61616?jms.redeliveryPolicy.maximumRedeliveries=0
</Resource>
<Resource id="jms/MyIncomingConnFactory"
type="javax.jms.ConnectionFactory" />
<Resource id="jms/MyOutgoingConnFactory"
type="javax.jms.ConnectionFactory" />
/
Tomee is smart enough to use XA for ActiveMQ too.
--
View this message in context:
http://tomee-openejb.979440.n4.nabble.com/Tomee-MySql-ActiveMQ-XA-Distributed-Transactions-tp4676680p4676751.html
Sent from the TomEE Users mailing list archive at Nabble.com.