Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

What are the ramifications of mixing JTA and non-JTA transactions where the same resources are involved?

0
Posted

What are the ramifications of mixing JTA and non-JTA transactions where the same resources are involved?

0

Location: http://www.jguru.com/faq/view.jsp?EID=2570 Created: Dec 14, 1999 Author: Jerry Smith (http://www.jguru.com/guru/viewbio.jsp?EID=9) It depends on the context/resource. In general, you shouldn’t create this type of heterogeneous transaction scenario, especially when working through a Java application server that shares objects such as database connections. In any situation where the possibility arises for both, design the application to use JTA transactions so that all transactions fall under the control of the transaction manager. If mixed transactions are necessary (for whatever reason), the application should manipulate the transactions in serial order, that is, start and finish the JTA transaction before creating the non-JTA transaction (or vice versa). If, for example, a JMS client creates a transaction via a UserTransaction and this transaction uses a database resource via the transaction manager, there could be problems if the same application directly accesses the datab

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123