You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by gd...@apache.org on 2008/03/18 20:16:58 UTC

svn commit: r638514 - in /webservices/axis2/trunk/java/modules/kernel: src/org/apache/axis2/engine/AxisConfiguration.java test-resources/deployment/module1/META-INF/module.xml

Author: gdaniels
Date: Tue Mar 18 12:16:57 2008
New Revision: 638514

URL: http://svn.apache.org/viewvc?rev=638514&view=rev
Log:
Fix logic in deployment to allow duplicate phase names - now as long as the deployment rules don't conflict a module can specify an existing phase.

Edit test module to make sure this functionality is working.

Modified:
    webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/AxisConfiguration.java
    webservices/axis2/trunk/java/modules/kernel/test-resources/deployment/module1/META-INF/module.xml

Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/AxisConfiguration.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/AxisConfiguration.java?rev=638514&r1=638513&r2=638514&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/AxisConfiguration.java (original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/engine/AxisConfiguration.java Tue Mar 18 12:16:57 2008
@@ -1203,17 +1203,21 @@
                 throw AxisFault.makeFault(e);
             }
         }
-        Phase phase = new Phase();
-        phase.setName(d.getName());
-        d.setTarget(phase);
 
         try {
             ec.deploy(d);
+
+            if (d.getTarget() == null) {
+                Phase phase = new Phase();
+                phase.setName(d.getName());
+                d.setTarget(phase);
+            }
+
             ec.rebuild();
         } catch (Exception e) {
             throw AxisFault.makeFault(e);
         }
-        
+
         phaseList = ec.getChain();
 
         return phaseList;

Modified: webservices/axis2/trunk/java/modules/kernel/test-resources/deployment/module1/META-INF/module.xml
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/test-resources/deployment/module1/META-INF/module.xml?rev=638514&r1=638513&r2=638514&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/test-resources/deployment/module1/META-INF/module.xml (original)
+++ webservices/axis2/trunk/java/modules/kernel/test-resources/deployment/module1/META-INF/module.xml Tue Mar 18 12:16:57 2008
@@ -54,4 +54,5 @@
     </operation>
     <phase name="NewPhase" before="Dispatch" after="Security" flow="InFlow"/>
     <phase name="NewPhase" before="Dispatch"  flow="InFaultFlow"/>
+    <phase name="Security" flow="InFlow"/> <!-- Make sure duplicates are OK -->
 </module>



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org