You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ode.apache.org by mr...@apache.org on 2008/04/11 00:59:51 UTC

svn commit: r646999 - /ode/trunk/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java

Author: mriou
Date: Thu Apr 10 15:59:46 2008
New Revision: 646999

URL: http://svn.apache.org/viewvc?rev=646999&view=rev
Log:
Optimization on assign, no need to save twice when a variable is initialized and then set.

Modified:
    ode/trunk/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java

Modified: ode/trunk/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java
URL: http://svn.apache.org/viewvc/ode/trunk/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java?rev=646999&r1=646998&r2=646999&view=diff
==============================================================================
--- ode/trunk/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java (original)
+++ ode/trunk/bpel-runtime/src/main/java/org/apache/ode/bpel/runtime/ASSIGN.java Thu Apr 10 15:59:46 2008
@@ -130,9 +130,10 @@
                     doc.appendChild(tempwrapper);
                     tempwrapper.appendChild(val);
                     val = tempwrapper;
-                } else
-                    doc.appendChild(val);
-                lval = initializeVariable(lvar, val);
+                } else doc.appendChild(val);
+                // Only external variables need to be initialized, others are new and going to be overwtitten
+                if (lvar.declaration.extVar != null) lval = initializeVariable(lvar, val);
+                else lval = val;
             } else
                 lval = fetchVariableData(lvar, true);
         }