Bugs item #559628, was opened at 2002-05-23 08:43 You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=376685&aid=559628&group_id=22866
Category: JBossServer Group: v2.4 (stable) Status: Open Resolution: None Priority: 7 Submitted By: Michael Hussey (mhussey) Assigned to: Nobody/Anonymous (nobody) Summary: Incorrectly throwing RollbackException Initial Comment: Using bean managed persistence, and container managed transactions, if the ejbStore method of an entity bean fails by throwing an EJBException, a javax.transaction.RollbackException is thrown instead of a javax.transaction.TransactionRolledBackException. This is a problem because the client will not be able to get a nested exception to find the original problem. For example, in our case, our EJBException wraps an exception describing which unique constraint was violated. The user needs that nested exception to modify his/her entry on the screen to successfully update the object. Weblogic throws its own exception in this case which extends RollbackException and has methods to obtain the nested exception. They also should be throwing TransactionRolledBackException for portability, but at least their solution is useable in the current form. I'm using jboss 2.4.4 windows 2000 ejb 2.0 dtd commit option A for the entity. ---------------------------------------------------------------------- >Comment By: Michael Hussey (mhussey) Date: 2002-05-28 13:42 Message: Logged In: YES user_id=357070 if you interpret the call to ejbStore as a method invocation on the bean, instead of some helper method called by the container, then it should throw TransactionRolledBackException because "the bean method (ejbStore) runs in the context of the callers transaction". ---------------------------------------------------------------------- Comment By: Michael Hussey (mhussey) Date: 2002-05-28 13:20 Message: Logged In: YES user_id=357070 I'm looking at the EJB 2.0 specifications from Sun: Please see table 15 on page 375. Or clarifying text on page 379 If the exception or error happened during the processing of a client invoked method, throw the java.rmi.RemoteException to the client if the client is a remote client or throw the javax.ejb.EJBException to the client if the client is a local client. If the instance exe-cuted in the client’s transaction, the Container should throw the javax.transac-tion. TransactionRolledbackException to a remote client or the javax.ejb.TransactionRolledbackLocalException to a local client, because it provides more information to the client. (The client knows that it is fruitless to continue the transaction.) ---------------------------------------------------------------------- You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=376685&aid=559628&group_id=22866 _______________________________________________________________ Don't miss the 2002 Sprint PCS Application Developer's Conference August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm _______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development