0 Replies Latest reply on Aug 21, 2002 4:05 PM by pajaroj

    JAWSPersistenceManager && java.lang.reflect.UndeclaredThrowa

    pajaroj

      I have a Stateless Session Bean that invokes in a method three Entity Beans. The Session bean manages the transaction with RequiresNew. The transaction-type for the Entity Beans is Required. The Session Bean is used from a JSP.

      Everything appear to be ok, but when the third Entity Bean in the transaction throws a SQL Exception, it is impossible to catch it in the Session Bean Method. Instead, we can only catch it at the JSP. The catched exception is java.lang.reflect.UndeclaredThrowableException.

      The workaround was to change the transaction type of the Entity Beans to RequiresNew, but when a error occurs only the transaction of the Entity Bean with problems is rolled back, not the entire transaction.

      Thanks

      Javier.