activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From krv <>
Subject XA Transaction with Spring, Mule+ActiveMQ, Hibernate+MySql and Atomikos
Date Fri, 22 Aug 2008 16:50:03 GMT

I have a very simple app which does this :

open an xa tx
            insert into db
            enqueue in mule (with activemq underneath)
            update db that i successfuly enqueued
close the xa tx

What i observe from the logs is :

first db update goes thro fine
enqueue also goes thro fine (of course it doesn't reflect in the ActiveMQ
web UI)
second db update also goes thro fine

but ..... just before the function returns (kicking off spring's tx close
part) I get this :

[org.mule.impl.DefaultExceptionStrategy]- Caught exception in Exception
Strategy: Session's XAResource has not been enlisted in a distributed
javax.jms.JMSException: Session's XAResource has not been enlisted in a
distributed transaction.

Unsure why this is happening when the xa tx actually has committed the DB
tx. If the exception occured should'nt the Db tx rollback ? Probably not
because MuleClient caches the msg which goes thro fine and another thread
(the MuleDispatcher thread ?) actually picks this up and this is causing the
exception ???

Either way not sure why my config is not working. I have attached my app
context file. Would appreciate if anyone could provide some pointers. Also I
have configured my Spring’s Hibernate sessionFactory to support an XA tx.
Hopefully this is correct ???
View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message