Author: mriou
Date: Wed Aug 20 11:19:18 2008
New Revision: 687407

URL: http://svn.apache.org/viewvc?rev=687407&view=rev
Log:
ODE-263 onAlarm is trigered only after completed activity.

Modified:
    
ode/branches/APACHE_ODE_1.X/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java

Modified: 
ode/branches/APACHE_ODE_1.X/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java
URL: 
http://svn.apache.org/viewvc/ode/branches/APACHE_ODE_1.X/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java?rev=687407&r1=687406&r2=687407&view=diff
==============================================================================
--- 
ode/branches/APACHE_ODE_1.X/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java
 (original)
+++ 
ode/branches/APACHE_ODE_1.X/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/INVOKE.java
 Wed Aug 20 11:19:18 2008
@@ -102,7 +102,7 @@
                     outboundMsg, invokeResponseChannel);
 
                 object(new 
InvokeResponseChannelListener(invokeResponseChannel) {
-                    private static final long serialVersionUID = 
4496880438819196765L;
+                    private static final long serialVerstmptmpionUID = 
4496880438819196765L;
 
                     public void onResponse() {
                         // we don't have to write variable data -> this already
@@ -189,7 +189,28 @@
                         }
                         getBpelRuntimeContext().releasePartnerMex(mexId);
                     }
-                });
+
+                }.or(new TerminationChannelListener(_self.self) {
+                    private static final long serialVersionUID = 
4219496341785922396L;
+
+                    public void terminate() {
+                       _self.parent.completed(null, 
CompensationHandler.emptySet());
+                       object(new 
InvokeResponseChannelListener(invokeResponseChannel) {
+                        private static final long serialVersionUID = 
688746737897792929L;
+                                               public void onFailure() {
+                                                       __log.debug("Failure on 
invoke ignored, the invoke has already been terminated: " + 
_oinvoke.toString());
+                                               }
+                                               public void onFault() {
+                            __log.debug("Fault on invoke ignored, the invoke 
has already been terminated: " + _oinvoke.toString());
+                                               }
+                                               public void onResponse() {
+                            __log.debug("Response on invoke ignored, the 
invoke has already been terminated: " + _oinvoke.toString());
+                                               }
+
+                    });
+                    }
+                }));
+;
             }
         } catch (FaultException fault) {
             __log.error(fault);


Reply via email to