Hi All,
I have deployed 2 ejbs (EJB1 and EJB2) with RequiresNew transaction attributes in IBM WSAD 5.1. The reis one method process() in EJB1 which internally calls a POJO. This POJO calls the executeLogic() method in EJB2 which performs a database insert and database update using Hibernate. Upon returning successfully from EJB2.executeLogic(), the POJO throws an exception.
This exception is caught by EJB1 and sessionCOntext.setRollbackOnly() is called. Unfortunately, this rolls back the entries posted by EJB2. Ideally I believe this should not happen because they both are deployed with RequiresNew transaction attributes for all methods.
Can anyone help me with this issue ? Please respond. Thanx.
Regards,
Sumukh.
-
IBM WSAD sessionContext.setRollbackOnly roll back issues (1 messages)
- Posted by: Sumukh Keni
- Posted on: July 04 2005 00:57 EDT
Threaded Messages (1)
- IBM WSAD sessionContext.setRollbackOnly roll back issues by Bharat Gandhari on July 07 2005 17:01 EDT
-
IBM WSAD sessionContext.setRollbackOnly roll back issues[ Go to top ]
- Posted by: Bharat Gandhari
- Posted on: July 07 2005 17:01 EDT
- in response to Sumukh Keni
I guess, the Transaction context of the session bean doesn't get propagated to the hibernate's transaction and hibernate might start its own transaction suspending the session bean's transaction.
Not sure though, Check the hibernate documentation.