aspose file tools*
The moose likes Object Relational Mapping and the fly likes JPA JOTM Transaction issue Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "JPA JOTM Transaction issue" Watch "JPA JOTM Transaction issue" New topic
Author

JPA JOTM Transaction issue

Praveen Pulluru
Greenhorn

Joined: Sep 26, 2013
Posts: 1


I'm developing a application with JPA(Hibernate) as backend. I have a DAO and JPADAO for each entity and my process updates more than one entity as one unit of work, so I decided to use JTA as it allows me to control the transactions so here's how my code looks persistence.xml














Now when I try to begin a transaction and commit changes to the entities(more than one) then it throws and exception and calls the utx.rollback but it will not rollback it has commited the transaction only partially not all entities are saved

Exception
java.lang.IllegalStateException: Cannot get Transaction for rollback
at org.objectweb.jotm.Current.rollback(Current.java:486)
at pub.jpa.dto.support.PubDProcess.processRecords(PubDProcess.java:397)

org.omg.CORBA.BAD_INV_ORDER: The Servant has not been associated with an ORB instance vmcid: 0x0 minor code: 0 completed: No
at org.omg.PortableServer.Servant._get_delegate(Unknown Source)
at org.omg.PortableServer.Servant._poa(Unknown Source)
at org.objectweb.jotm._SubCoordinator_Tie.deactivate(Unknown Source)
at com.sun.corba.se.impl.javax.rmi.CORBA.Util.cleanUpTie(Unknown Source)
at com.sun.corba.se.impl.javax.rmi.CORBA.Util.unexportObject(Unknown Source)
at javax.rmi.CORBA.Util.unexportObject(Unknown Source)
at com.sun.corba.se.impl.javax.rmi.PortableRemoteObject.unexportObject(Unknown Source)
at javax.rmi.PortableRemoteObject.unexportObject(Unknown Source)

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JPA JOTM Transaction issue