-
Bug
-
Resolution: Done
-
Major
-
None
-
None
When applications call javax.persistence.Persistence.generateSchema() from active JTA transactions, Hibernate defaults to using org.hibernate.engine.transaction.jta.platform.internal.JBossStandAloneJtaPlatform, which uses com.arjuna.ats.jta.TransactionManager. We cannot use com.arjuna.ats.jta.TransactionManager directly anymore, instead we need to use the WildFly transaction client layer which wraps Arjuna TM.
https://paste.fedoraproject.org/paste/9y4vn4E0yT77u471LNL-Xw shows the call stack of where error is thrown by LocalTransaction.verifyAssociation:
Caused by: java.lang.IllegalStateException: WFTXN0073: Unexpected provider transaction mismatch; expected TransactionImple < ac, BasicAction: 0:ffff0a0000b0:3831261e:5b045a43:11 status: ActionStatus.RUNNING >, got null[javatest.batch] 13:59:36,576 INFO [stdout] (Thread-130)
at org.wildfly.transaction.client.LocalTransaction.verifyAssociation(LocalTransaction.java:245)