Atomikos Forum

Spring XA datasource example fails

The example in the examples/spring/jdbc doesn't work if I try and use the XA datasource. Is there an existing working configuration example of how to get XA datasources going with spring?

I have spend a couple of days trying different configuration attempts but have not managed to get it to work.I tried to show my configuration attempts in this post but the forum software throws a database error whenever I try post my XML. I have contacted support about this problem.

A working example of an XA datasource would be extremely useful.
Gavin DOnald Send private email
Saturday, August 02, 2008
 
 
After changing my configurations again I am getting the error:

Caused by: com.atomikos.jdbc.AtomikosSQLException: cannot initialize AtomikosDataSourceBean: XAConnectionFactory: failed to create pooled connection

which is the same error I get when running the spring example. I am using MySQL version 5.0.15a.
Gavin DOnald Send private email
Saturday, August 02, 2008
 
 
I am not sure what I have done but that error seems to have gone now. I know that I have switched the property:

<prop key="portNumber">3306</prop>

to become:

<prop key="port">3306</prop>

and also applied the patch to the MySQL connector described here:

http://bugs.mysql.com/bug.php?id=35489

What I now have is the two XA datasources that allow me to read and write to the two databases but I don't seem to have transactional functionality.

My understanding is that Spring+Hibernate will handle all of the transaction setup for me and Atomikos will manage the transactions.

If I simply change the password for database B then should that not be enough to prevent the transaction from committing to database A? When I do that I get a:

com.atomikos.jdbc.AtomikosSQLException: cannot initialize AtomikosDataSourceBean: XAConnectionFactory: failed to create pooled connection

and the application doesn't start. Doea anyone have any suggestions?
Gavin DOnald Send private email
Saturday, August 02, 2008
 
 
Please see our comments sent by email, and reply to the mail if you any further questions.
Guy Pardon Send private email
Monday, August 04, 2008
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics