Hi Tammo, Related to this commit, I tend to think it's better to let the BpelEventListener runtime exceptions bubble up to the engine and force a transaction rollback by default rather than catching everything and outputting a warning. This allows event logging to be transactional/atomic together with the engine (very desired). If event loss is tolerated, the exception handling/masking can happen inside the EventListener itself.
What do you think? alex On 10/19/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Author: vanto > Date: Fri Oct 19 08:57:27 2007 > New Revision: 586512 > > URL: http://svn.apache.org/viewvc?rev=586512&view=rev > Log: > fixes ODE-199 in 1.1 branch > > Modified: > > > ode/branches/APACHE_ODE_1.1/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java > > > ode/branches/APACHE_ODE_1.1/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelProcess.java > > > ode/branches/APACHE_ODE_1.1/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelRuntimeContextImpl.java > > Modified: > ode/branches/APACHE_ODE_1.1/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java > URL: > http://svn.apache.org/viewvc/ode/branches/APACHE_ODE_1.1/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java?rev=586512&r1=586511&r2=586512&view=diff > > ============================================================================== > --- > ode/branches/APACHE_ODE_1.1/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java > (original) > +++ > ode/branches/APACHE_ODE_1.1/bpel-runtime/src/main/java/org/apache/ode/bpel/engine/BpelEngineImpl.java > Fri Oct 19 08:57:27 2007 > @@ -419,7 +419,12 @@ > // Note that the eventListeners list is a copy-on-write array, so > need > // to mess with synchronization. > for (org.apache.ode.bpel.iapi.BpelEventListener l : > _contexts.eventListeners) { > - l.onEvent(event); > + try { > + l.onEvent(event); > + } catch (Throwable t) { > + // catch all possible exceptions > + __log.warn("Got an exception while notifying > BpelEventListener '" + l + "'.", t); > + } > } > } >
