You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@synapse.apache.org by sa...@apache.org on 2006/01/02 08:32:48 UTC

svn commit: r365305 - /incubator/synapse/trunk/java/src/org/apache/synapse/axis2/Axis2FlexibleMEPClient.java

Author: saminda
Date: Sun Jan  1 23:32:41 2006
New Revision: 365305

URL: http://svn.apache.org/viewcvs?rev=365305&view=rev
Log:
add a reminder to axi2Flexiblemepclient

Modified:
    incubator/synapse/trunk/java/src/org/apache/synapse/axis2/Axis2FlexibleMEPClient.java

Modified: incubator/synapse/trunk/java/src/org/apache/synapse/axis2/Axis2FlexibleMEPClient.java
URL: http://svn.apache.org/viewcvs/incubator/synapse/trunk/java/src/org/apache/synapse/axis2/Axis2FlexibleMEPClient.java?rev=365305&r1=365304&r2=365305&view=diff
==============================================================================
--- incubator/synapse/trunk/java/src/org/apache/synapse/axis2/Axis2FlexibleMEPClient.java (original)
+++ incubator/synapse/trunk/java/src/org/apache/synapse/axis2/Axis2FlexibleMEPClient.java Sun Jan  1 23:32:41 2006
@@ -22,11 +22,7 @@
 import org.apache.axis2.context.MessageContext;
 import org.apache.axis2.context.ServiceContext;
 import org.apache.axis2.context.ServiceGroupContext;
-import org.apache.axis2.description.AxisOperation;
-import org.apache.axis2.description.AxisService;
-import org.apache.axis2.description.AxisServiceGroup;
-import org.apache.axis2.description.OutInAxisOperation;
-import org.apache.axis2.description.TransportOutDescription;
+import org.apache.axis2.description.*;
 import org.apache.axis2.engine.AxisConfiguration;
 import org.apache.axis2.engine.AxisEngine;
 
@@ -55,14 +51,18 @@
             AxisConfiguration ac = new AxisConfiguration();
             ConfigurationContext cc = new ConfigurationContext(ac);
             AxisServiceGroup asg = new AxisServiceGroup(ac);
-            AxisService as = new AxisService("AnonymousService");
+            AxisService as = new AxisService("__ANONYMOUS_SERVICE__");
             asg.addService(as);
             ServiceGroupContext sgc = new ServiceGroupContext(cc, asg);
             ServiceContext sc = sgc.getServiceContext(as);
-            AxisOperation axisOperationTemplate = new OutInAxisOperation(
-                    new QName("TemplateOperation"));
-            as.addOperation(axisOperationTemplate);
+            //todo: explicitly assumes __OPERATION_OUT_IN__
+            //todo: need a way to support others __OPERATION_OUT_ONLY__ , __OPERATION_ROBUST_OUT_ONLY__
+            AxisOperation axisOperationTemplateOutIn = new OutInAxisOperation(
+                    new QName("__OPERATION_OUT_IN__"));
+            as.addOperation(axisOperationTemplateOutIn);
             cc.getAxisConfiguration().addService(as);
+            // todo: TransportOutDescription handles Http only. Need to integrate other
+            // todo: transports too.
             TransportOutDescription tod = new TransportOutDescription(
                     new QName(org.apache.axis2.Constants.TRANSPORT_HTTP));
             tod.setSender(new CommonsHTTPTransportSender());
@@ -119,7 +119,7 @@
             }
             // initialize and set the Operation Context
 
-            msgCtx.setOperationContext(axisOperationTemplate
+            msgCtx.setOperationContext(axisOperationTemplateOutIn
                     .findOperationContext(msgCtx, sc));
             AxisEngine engine = new AxisEngine(cc);
 
@@ -164,7 +164,6 @@
             SOAPEnvelope resenvelope = TransportUtils.createSOAPMessage(
                     response, msgCtx.getEnvelope().getNamespace().getName());
 
-            System.out.println(resenvelope.toString());
 
             response.setEnvelope(resenvelope);
             engine = new AxisEngine(msgCtx.getConfigurationContext());



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