Changes committed to the database immediately when using the Hibernate Work API in EAP 6

Solution Verified - Updated -

Issue

  • A persistence unit is defined and bound to a datsource using <jta-data-source> in the persistence.xml
  • UserTransaction is used to begin/commit a transaction
  • After executing a database write using the Hibernate Work API the write is seen to be committed without UserTransaction.commit()
  • Even calling UserTransaction.rollback() does not rollback the writes

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP) 6
  • Hibernate 4

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content