Re: SpringTransactionManager and ChainedTransactionManager

2018-02-09 Thread smurphy
In actuality I rewrote the tests and removed the
AbstractTransactionalJUnit4SpringContextTests super class and the
transactions worked. I also rewrote the the test as an integration test on a
tomcat server and confirmed that the transaction managers worked.

I did see the same javadoc comments that you mentioned and found that the
order was not important. Also, from the following article that is references
in Spring's Transaction documentation:

ChainedTransactionManager which is ‘a crude implementation of a transaction
manager just links together a list of other transaction managers to
implement the transaction synchronization. If the business processing is
successful they all commit, and if not they all roll back.”

Full article: 

https://www.javaworld.com/article/2077963/open-source-tools/distributed-transactions-in-spring--with-and-without-xa.html?page=2



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/


Re: SpringTransactionManager and ChainedTransactionManager

2018-02-02 Thread vkulichenko
ChainedTransactionManager doesn't guarantee that both transactions will be
rolled back in both cases, here is a quote from JavaDoc:

Using this implementation assumes that errors causing a transaction rollback
will usually happen before the transaction completion or during the commit
of the *most inner PlatformTransactionManager*.

So behavior basically depends on the order transaction managers are
provided. If you want to have a single transaction that spawns two data
sources, you should use JTA. Ignite has integration with it:
https://apacheignite.readme.io/docs/transactions#integration-with-jta

-Val



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/