Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JTA Transaction rollback exception

 
abhijit Ohal
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When one of the sql query get failed to execute i need to rollback transaction, so i get an exception " JTA Transaction rollback Failed exception" .but i remove following property from cfg files

......

<hibernate-configuration>
<session-factory>
<property name="transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</property>
.........................

It works fine. I am using JBOSS server for developement

see some logs below.Please anybody help me .

JTA rollback failed
java.lang.IllegalStateException: No transaction.
at org.jboss.tm.TxManager.setRollbackOnly(TxManager.java:356)
at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.setRollbackOnly(ServerVMClientUserTransaction.java:141)
at org.hibernate.transaction.JTATransaction.rollback(JTATransaction.java:179)
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well it looks like it is trying to rollback a transaction, but there is no transaction there to begin with.

Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic