I have migrated from WebSphere 8.5.5 with Hibernate 4.2 to JBoss EAP 7.1.5 + Hibernate 5.1.16. In WebSphere with Hibernate 4.2, I can separate Hibernate trasnaction from EJB one by using following coding. However, it does not work in JBoss EAP with Hibernate 5.1.16. In fact, I want commit data whatever associated EJB transaction is rollback/commit. Please help.
I have checked our code, we have been implementing BMT. In fact, we would have to write database to record error when BMT transaction get problem. So, we want to commit it by using separated transaction inside BMT even BMT is rollback.
I think it is common requirement and Hibernate 3 & 4 are working.
In fact, we would have to write database to record error when BMT transaction get problem.
If the Tx failed, you can no longer use the same Hibernate Session, you need to start a new Session and Transaction.
So, we want to commit it by using separated transaction inside BMT even BMT is rollback.
You need to check the JBoss documentation or ask their forum for the best solution to this problem.
I think it is common requirement and Hibernate 3 & 4 are working.
Transaction handling happens in JBoss, so I don’t think this is a Hibernate issue. It worked with Hibernate 3 and 4 because you were using a different JBoss application server version.
Thanks for your kindly reply. Btw, I have solved the problem by setting Hibernate 5.1 configuration. For your information, I used JBoss 7.1.5 + Hibernate 4 is also OK before migrate to Hibernate 5.1.