ws-sandesha-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chamik...@apache.org
Subject svn commit: r370393 - in /webservices/sandesha/trunk/samples/src/sandesha2/samples: interop/AsyncEchoClient.java interop/AsyncPingClient.java interop/SyncEchoClient.java interop/SyncPingClient.java simpleServer/SimpleSandesha2Server.java
Date Thu, 19 Jan 2006 06:03:57 GMT
Author: chamikara
Date: Wed Jan 18 22:03:17 2006
New Revision: 370393

URL: http://svn.apache.org/viewcvs?rev=370393&view=rev
Log:
Changed the samples to comply with the changes in Axis2.

Modified:
    webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncEchoClient.java
    webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncPingClient.java
    webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncEchoClient.java
    webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncPingClient.java
    webservices/sandesha/trunk/samples/src/sandesha2/samples/simpleServer/SimpleSandesha2Server.java

Modified: webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncEchoClient.java
URL: http://svn.apache.org/viewcvs/webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncEchoClient.java?rev=370393&r1=370392&r2=370393&view=diff
==============================================================================
--- webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncEchoClient.java
(original)
+++ webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncEchoClient.java
Wed Jan 18 22:03:17 2006
@@ -78,7 +78,9 @@
 			return;
 		}
 		
-		ConfigurationContext configContext = new ConfigurationContextFactory().createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH);
+		String axis2_xml = AXIS2_CLIENT_PATH + "axis2.xml";
+     
+		ConfigurationContext configContext = ConfigurationContextFactory.createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH,axis2_xml);
 
 		ServiceClient serviceClient = new ServiceClient (configContext,null);
 		
@@ -96,7 +98,8 @@
 		
 		serviceClient.setOptions(clientOptions);
 		serviceClient.engageModule(new QName ("Sandesha2-0.9"));
-		
+		//clientOptions.setProperty(MessageContextConstants.CHUNKED,Constants.VALUE_FALSE);
+		//clientOptions.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
 		String offeredSequenceID = SandeshaUtil.getUUID();
 		clientOptions.setProperty(Sandesha2ClientAPI.OFFERED_SEQUENCE_ID,offeredSequenceID);  //Optional
 		
@@ -105,11 +108,16 @@
 		Callback callback2 = new TestCallback ("Callback 2");
 		serviceClient.sendReceiveNonblocking(getEchoOMBlock("echo2"),callback2);
 		
-		clientOptions.setProperty(Sandesha2ClientAPI.LAST_MESSAGE, "true");
 		Callback callback3 = new TestCallback ("Callback 3");
 		serviceClient.sendReceiveNonblocking(getEchoOMBlock("echo3"),callback3);
+		Callback callback4 = new TestCallback ("Callback 4");
+		serviceClient.sendReceiveNonblocking(getEchoOMBlock("echo4"),callback4);
+		
+		clientOptions.setProperty(Sandesha2ClientAPI.LAST_MESSAGE, "true");
+		Callback callback5 = new TestCallback ("Callback 5");
+		serviceClient.sendReceiveNonblocking(getEchoOMBlock("echo5"),callback5);
 		
-        while (!callback3.isComplete()) {
+        while (!callback5.isComplete()) {
             Thread.sleep(1000);
         }
        

Modified: webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncPingClient.java
URL: http://svn.apache.org/viewcvs/webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncPingClient.java?rev=370393&r1=370392&r2=370393&view=diff
==============================================================================
--- webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncPingClient.java
(original)
+++ webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/AsyncPingClient.java
Wed Jan 18 22:03:17 2006
@@ -71,7 +71,8 @@
 			return;
 		}
 		
-		ConfigurationContext configContext = new ConfigurationContextFactory().createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH);
+		String axis2_xml = AXIS2_CLIENT_PATH + "axis2.xml";
+		ConfigurationContext configContext = ConfigurationContextFactory.createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH,axis2_xml);
 
 		ServiceClient serviceClient = new ServiceClient (configContext,null);
 		

Modified: webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncEchoClient.java
URL: http://svn.apache.org/viewcvs/webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncEchoClient.java?rev=370393&r1=370392&r2=370393&view=diff
==============================================================================
--- webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncEchoClient.java (original)
+++ webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncEchoClient.java Wed
Jan 18 22:03:17 2006
@@ -72,8 +72,8 @@
 			return;
 		}
 		
-		
-		ConfigurationContext configContext = new ConfigurationContextFactory().createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH);
+		String axis2_xml = AXIS2_CLIENT_PATH + "axis2.xml";
+		ConfigurationContext configContext = ConfigurationContextFactory.createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH,axis2_xml);
 
 		ServiceClient serviceClient = new ServiceClient (configContext,null);
 		

Modified: webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncPingClient.java
URL: http://svn.apache.org/viewcvs/webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncPingClient.java?rev=370393&r1=370392&r2=370393&view=diff
==============================================================================
--- webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncPingClient.java (original)
+++ webservices/sandesha/trunk/samples/src/sandesha2/samples/interop/SyncPingClient.java Wed
Jan 18 22:03:17 2006
@@ -19,6 +19,7 @@
 import javax.xml.namespace.QName;
 
 import org.apache.axis2.AxisFault;
+import org.apache.axis2.Constants;
 import org.apache.axis2.addressing.EndpointReference;
 import org.apache.axis2.client.InOnlyMEPClient;
 import org.apache.axis2.client.MessageSender;
@@ -27,6 +28,7 @@
 import org.apache.axis2.client.ServiceClient;
 import org.apache.axis2.context.ConfigurationContext;
 import org.apache.axis2.context.ConfigurationContextFactory;
+import org.apache.axis2.context.MessageContextConstants;
 import org.apache.axis2.description.AxisService;
 import org.apache.axis2.engine.AxisConfiguration;
 import org.apache.axis2.engine.MessageReceiver;
@@ -71,13 +73,17 @@
 			System.out.println("ERROR: Please change <SANDESHA2_HOME> to your Sandesha2 installation
directory.");
 			return;
 		}
-		ConfigurationContext configContext = new ConfigurationContextFactory().createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH);
+		
+		String axis2_xml = AXIS2_CLIENT_PATH + "axis2.xml";
+		ConfigurationContext configContext = ConfigurationContextFactory.createConfigurationContextFromFileSystem(AXIS2_CLIENT_PATH,axis2_xml);
 		
 		Options clientOptions = new Options ();
 	//	clientOptions.setr\
 		clientOptions.setProperty(Options.COPY_PROPERTIES, new Boolean (true));
 		clientOptions.setTo(new EndpointReference (toEPR));
 		clientOptions.setProperty(Sandesha2ClientAPI.SEQUENCE_KEY,"sequence1");
+	//	clientOptions.setProperty(MessageContextConstants.CHUNKED,Constants.VALUE_FALSE);
+		
 		
 		ServiceClient serviceClient = new ServiceClient (configContext,null);
 		//serviceClient.

Modified: webservices/sandesha/trunk/samples/src/sandesha2/samples/simpleServer/SimpleSandesha2Server.java
URL: http://svn.apache.org/viewcvs/webservices/sandesha/trunk/samples/src/sandesha2/samples/simpleServer/SimpleSandesha2Server.java?rev=370393&r1=370392&r2=370393&view=diff
==============================================================================
--- webservices/sandesha/trunk/samples/src/sandesha2/samples/simpleServer/SimpleSandesha2Server.java
(original)
+++ webservices/sandesha/trunk/samples/src/sandesha2/samples/simpleServer/SimpleSandesha2Server.java
Wed Jan 18 22:03:17 2006
@@ -42,7 +42,10 @@
 		}
 		
 		System.out.println("Starting sandesha2 server...");
-		SimpleHTTPServer server = new SimpleHTTPServer (AXIS2_SERVER_PATH,8080);
+		
+		String axis2_xml = AXIS2_SERVER_PATH + "axis2.xml";
+		SimpleHTTPServer server = new SimpleHTTPServer (AXIS2_SERVER_PATH,axis2_xml,8080);
+		
 		server.start();
 	}
 }



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


Mime
View raw message