• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JTA System Exception in the Rollback block

 
Malli Raman
Ranch Hand
Posts: 312
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am new to JTA API.In JTA API, UserTransaction.rollback throws javax.transaction.SystemException. In this case, if any SystemException arises what will be the condition of the transaction.
let say utx is the userTransaction Object.
try
{
utx.begin();
.....
some transaction takes place
.....
utx.commit()
}
catch(Exception e)
{
try
{
utx.rollback();
}
catch(javax.transaction.SystemException se)
{
System.out.println("System Exception occured in the Rollback");
}
}
So In this case if any exception occures in the main Block and rollback throws any system exception then what will happen to the transaction.
Regards,
M.S.Raman.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic