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 ch...@apache.org on 2005/11/30 09:26:03 UTC
svn commit: r349908 [2/3] - in /webservices/axis2/trunk/java/modules:
codegen/src/org/apache/axis2/wsdl/template/java/
codegen/test/org/apache/axis2/rpc/ core/src/org/apache/axis2/client/
core/src/org/apache/axis2/context/ core/src/org/apache/axis2/eng...
Modified: webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/complex/EchoBlockingClient.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/complex/EchoBlockingClient.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/complex/EchoBlockingClient.java (original)
+++ webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/complex/EchoBlockingClient.java Wed Nov 30 00:23:02 2005
@@ -20,6 +20,7 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.om.OMElement;
public class EchoBlockingClient {
@@ -34,10 +35,12 @@
Call call = new Call();
- call.setTo(targetEPR);
- call.setExceptionToBeThrownOnSOAPFault(false);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,Constants.TRANSPORT_HTTP,false);
- call.setSoapAction(soapAction);
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setExceptionToBeThrownOnSOAPFault(false);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,Constants.TRANSPORT_HTTP,false);
+ options.setSoapAction(soapAction);
//Blocking invocation
Modified: webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/simple/EchoBlockingClient.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/simple/EchoBlockingClient.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/simple/EchoBlockingClient.java (original)
+++ webservices/axis2/trunk/java/modules/integration/src/test/interop/sun/round4/simple/EchoBlockingClient.java Wed Nov 30 00:23:02 2005
@@ -20,8 +20,9 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
-import test.interop.sun.round4.simple.util.SunGroupHClientUtil;
+import org.apache.axis2.client.Options;
import org.apache.axis2.om.OMElement;
+import test.interop.sun.round4.simple.util.SunGroupHClientUtil;
public class EchoBlockingClient {
public OMElement sendMsg(SunGroupHClientUtil util,String soapAction){
@@ -32,10 +33,12 @@
Call call = new Call();
- call.setTo(targetEPR);
- call.setExceptionToBeThrownOnSOAPFault(false);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,Constants.TRANSPORT_HTTP,false);
- call.setSoapAction(soapAction);
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setExceptionToBeThrownOnSOAPFault(false);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,Constants.TRANSPORT_HTTP,false);
+ options.setSoapAction(soapAction);
//Blocking invocation
firstchild = call.invokeBlocking("",util.getEchoOMElement());
Modified: webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round1/Round1Client.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round1/Round1Client.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round1/Round1Client.java (original)
+++ webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round1/Round1Client.java Wed Nov 30 00:23:02 2005
@@ -20,14 +20,15 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisOperation;
import org.apache.axis2.description.OutInAxisOperation;
import org.apache.axis2.engine.AxisConfiguration;
import org.apache.axis2.engine.AxisConfigurationImpl;
-import test.interop.whitemesa.round1.util.Round1ClientUtil;
import org.apache.axis2.soap.SOAPEnvelope;
+import test.interop.whitemesa.round1.util.Round1ClientUtil;
import javax.xml.namespace.QName;
import java.net.MalformedURLException;
@@ -46,10 +47,15 @@
throw new AxisFault(e);
}
- Call call = new Call("target/test-resources/intregrationRepo");
- call.setTo(new EndpointReference(url.toString()));
- call.setSoapAction(soapAction);
- call.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+ String clientHome = "target/test-resources/intregrationRepo";
+
+ Options options = new Options();
+ options.setTo(new EndpointReference(url.toString()));
+ options.setSoapAction(soapAction);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+
+ Call call = new Call(clientHome);
+ call.setClientOptions(options);
SOAPEnvelope reqEnv = util.getEchoSoapEnvelope();
Modified: webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round2/SunRound2Client.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round2/SunRound2Client.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round2/SunRound2Client.java (original)
+++ webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round2/SunRound2Client.java Wed Nov 30 00:23:02 2005
@@ -20,14 +20,15 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisOperation;
import org.apache.axis2.description.OutInAxisOperation;
import org.apache.axis2.engine.AxisConfiguration;
import org.apache.axis2.engine.AxisConfigurationImpl;
-import test.interop.whitemesa.round2.util.SunRound2ClientUtil;
import org.apache.axis2.soap.SOAPEnvelope;
+import test.interop.whitemesa.round2.util.SunRound2ClientUtil;
import javax.xml.namespace.QName;
import java.net.URL;
@@ -42,9 +43,12 @@
try {
call = new Call("target/test-resources/intregrationRepo");
url = new URL(epUrl);
- call.setTo(new EndpointReference(url.toString()));
- call.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
- call.setSoapAction(soapAction);
+
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(new EndpointReference(url.toString()));
+ options.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+ options.setSoapAction(soapAction);
AxisConfiguration axisConfig = new AxisConfigurationImpl();
ConfigurationContext configCtx = new ConfigurationContext(axisConfig);
Modified: webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round3/SunRound3Client.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round3/SunRound3Client.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round3/SunRound3Client.java (original)
+++ webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round3/SunRound3Client.java Wed Nov 30 00:23:02 2005
@@ -20,14 +20,15 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisOperation;
import org.apache.axis2.description.OutInAxisOperation;
import org.apache.axis2.engine.AxisConfiguration;
import org.apache.axis2.engine.AxisConfigurationImpl;
-import test.interop.whitemesa.round3.util.SunRound3ClientUtil;
import org.apache.axis2.soap.SOAPEnvelope;
+import test.interop.whitemesa.round3.util.SunRound3ClientUtil;
import javax.xml.namespace.QName;
import java.net.URL;
@@ -36,16 +37,19 @@
public SOAPEnvelope sendMsg(SunRound3ClientUtil util, String epUrl, String soapAction) throws AxisFault {
- SOAPEnvelope retEnvelope= null;
+ SOAPEnvelope retEnvelope = null;
Call call = null;
URL url = null;
try {
call = new Call("target/test-resources/intregrationRepo");
//todo set the path to repository in Call()
url = new URL(epUrl);
- call.setTo(new EndpointReference(url.toString()));
- call.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
- call.setSoapAction(soapAction);
+
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(new EndpointReference(url.toString()));
+ options.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+ options.setSoapAction(soapAction);
AxisConfiguration axisConfig = new AxisConfigurationImpl();
ConfigurationContext configCtx = new ConfigurationContext(axisConfig);
Modified: webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/complex/EchoBlockingClient.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/complex/EchoBlockingClient.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/complex/EchoBlockingClient.java (original)
+++ webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/complex/EchoBlockingClient.java Wed Nov 30 00:23:02 2005
@@ -20,8 +20,9 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
-import test.interop.whitemesa.round4.complex.utils.WhitemesaR4ClientUtil;
+import org.apache.axis2.client.Options;
import org.apache.axis2.om.OMElement;
+import test.interop.whitemesa.round4.complex.utils.WhitemesaR4ClientUtil;
public class EchoBlockingClient {
@@ -35,10 +36,13 @@
Call call = new Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setExceptionToBeThrownOnSOAPFault(false);
- call.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
- call.setSoapAction(soapAction);
+
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setExceptionToBeThrownOnSOAPFault(false);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+ options.setSoapAction(soapAction);
//Blocking invocation
Modified: webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/simple/EchoBlockingClient.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/simple/EchoBlockingClient.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/simple/EchoBlockingClient.java (original)
+++ webservices/axis2/trunk/java/modules/integration/src/test/interop/whitemesa/round4/simple/EchoBlockingClient.java Wed Nov 30 00:23:02 2005
@@ -20,8 +20,9 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
-import test.interop.whitemesa.round4.simple.utils.WhitemesaR4ClientUtil;
+import org.apache.axis2.client.Options;
import org.apache.axis2.om.OMElement;
+import test.interop.whitemesa.round4.simple.utils.WhitemesaR4ClientUtil;
public class EchoBlockingClient {
@@ -35,10 +36,13 @@
Call call = new Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setExceptionToBeThrownOnSOAPFault(false);
- call.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
- call.setSoapAction(soapAction);
+
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setExceptionToBeThrownOnSOAPFault(false);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+ options.setSoapAction(soapAction);
//Blocking invocation
firstchild = call.invokeBlocking("", util.getEchoOMElement());
Modified: webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultB.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultB.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultB.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultB.java Wed Nov 30 00:23:02 2005
@@ -73,9 +73,9 @@
if (attributePresent)
headerBlock.removeAttribute((OMAttribute) headerBlock.getAllAttributes().next());
headerBlockPresent = new Integer(1);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
headerAdd.addChild(headerBlock);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd);
}
} else {
@@ -125,9 +125,9 @@
//e.printStackTrace();
}
headerBlockPresent = new Integer(1);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
headerAdd.addChild(newHeaderBlock);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd);
throw new AxisFault("Intentional Failure from SOAP 1.2 testing ...");
}
@@ -139,12 +139,12 @@
}
}
if (headerBlockPresent.equals(new Integer(0))) {
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
}
headerBlockPresent = new Integer(0);
} else {
headerBlockPresent = new Integer(0);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
}
}
}
Modified: webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java Wed Nov 30 00:23:02 2005
@@ -31,9 +31,9 @@
}
public void invoke(MessageContext msgContext) {
- Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT", true);
+ Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT");
if (headerBlockPresent.equals(new Integer(1))) {
- SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK", true);
+ SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK");
Iterator headerBlocks = headerAdd.examineAllHeaderBlocks();
while(headerBlocks.hasNext()){
SOAPHeaderBlock headerBlock=(SOAPHeaderBlock) headerBlocks.next();
Modified: webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleB/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java Wed Nov 30 00:23:02 2005
@@ -31,9 +31,9 @@
}
public void invoke(MessageContext msgContext) {
- Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT", true);
+ Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT");
if (headerBlockPresent.equals(new Integer(1))) {
- SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK", true);
+ SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK");
Iterator headerBlocks = headerAdd.examineAllHeaderBlocks();
while(headerBlocks.hasNext()){
SOAPHeaderBlock headerBlock=(SOAPHeaderBlock) headerBlocks.next();
Modified: webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultC.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultC.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultC.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12InFlowHandlerDefaultC.java Wed Nov 30 00:23:02 2005
@@ -75,9 +75,9 @@
attributePresent = false;
}
headerBlockPresent = new Integer(1);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
headerAdd.addChild(headerBlock);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd);
}
} else {
@@ -107,8 +107,8 @@
node.setNodeValue(SAMPLE_ROLE + "/" + ROLE_BY_B);
SOAPFaultRole role = factory.createSOAPFaultRole(fault);
role.setRoleValue(SAMPLE_ROLE + "/" + ROLE_BY_B);
- msgContext.setProperty(SOAP12Constants.SOAP_FAULT_NODE_LOCAL_NAME, node, true);
- msgContext.setProperty(SOAP12Constants.SOAP_FAULT_ROLE_LOCAL_NAME, role, true);
+ msgContext.setProperty(SOAP12Constants.SOAP_FAULT_NODE_LOCAL_NAME, node);
+ msgContext.setProperty(SOAP12Constants.SOAP_FAULT_ROLE_LOCAL_NAME, role);
}
msgContext.setProperty(SOAP12Constants.SOAP_FAULT_CODE_LOCAL_NAME, code);
@@ -129,9 +129,9 @@
//e.printStackTrace();
}
headerBlockPresent = new Integer(1);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
headerAdd.addChild(newHeaderBlock);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK", headerAdd);
throw new AxisFault("Intentional Failure from SOAP 1.2 testing ...");
}
}
@@ -140,14 +140,14 @@
}
}
if (headerBlockPresent.equals(new Integer(0))) {
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
}
headerBlockPresent = new Integer(0);
} else {
headerBlockPresent = new Integer(0);
- msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent, true);
+ msgContext.getOperationContext().setProperty("HEADER_BLOCK_PRESENT", headerBlockPresent);
}
}
}
Modified: webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFaultFlowHandlerDefault.java Wed Nov 30 00:23:02 2005
@@ -31,9 +31,9 @@
}
public void invoke(MessageContext msgContext) {
- Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT", true);
+ Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT");
if (headerBlockPresent.equals(new Integer(1))) {
- SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK", true);
+ SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK");
Iterator headerBlocks = headerAdd.examineAllHeaderBlocks();
while(headerBlocks.hasNext()){
SOAPHeaderBlock headerBlock=(SOAPHeaderBlock) headerBlocks.next();
Modified: webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test-resources/SOAP12Testing/SOAP12TestModuleC/org/apache/axis2/soap12testing/handlers/SOAP12OutFlowHandlerDefault.java Wed Nov 30 00:23:02 2005
@@ -31,9 +31,9 @@
}
public void invoke(MessageContext msgContext) {
- Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT", true);
+ Integer headerBlockPresent = (Integer) msgContext.getOperationContext().getProperty("HEADER_BLOCK_PRESENT");
if (headerBlockPresent.equals(new Integer(1))) {
- SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK", true);
+ SOAPHeader headerAdd = (SOAPHeader) msgContext.getOperationContext().getProperty("HEADER_BLOCK");
Iterator headerBlocks = headerAdd.examineAllHeaderBlocks();
while(headerBlocks.hasNext()){
SOAPHeaderBlock headerBlock=(SOAPHeaderBlock) headerBlocks.next();
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CallUnregisteredServiceTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CallUnregisteredServiceTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CallUnregisteredServiceTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CallUnregisteredServiceTest.java Wed Nov 30 00:23:02 2005
@@ -23,6 +23,7 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.integration.UtilServer;
import org.apache.axis2.om.OMAbstractFactory;
import org.apache.axis2.om.OMElement;
@@ -67,10 +68,14 @@
new EndpointReference("http://127.0.0.1:"
+ (UtilServer.TESTING_PORT)
+ "/axis/services/EchoXMLService1");
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
- call.setTo(targetEPR);
+ options.setTo(targetEPR);
+
SOAPEnvelope resEnv =
(SOAPEnvelope) call.invokeBlocking(
"echoOMElement", method);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CharactersetEncodingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CharactersetEncodingTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CharactersetEncodingTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CharactersetEncodingTest.java Wed Nov 30 00:23:02 2005
@@ -15,10 +15,12 @@
*/
package org.apache.axis2.engine;
+
import junit.framework.TestCase;
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.util.TestConstants;
@@ -32,7 +34,7 @@
import org.apache.commons.logging.LogFactory;
/**
- * Testing charater encoding support
+ * Testing character encoding support
*/
public class CharactersetEncodingTest extends TestCase implements TestConstants {
@@ -63,7 +65,6 @@
}
-
private void runTest(String value, String expected) {
try {
@@ -76,15 +77,15 @@
Call call = new Call(
Constants.TESTING_PATH + "chuncked-enabledRepository");
- call.set(MessageContext.CHARACTER_SET_ENCODING, "UTF-16");
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setProperty(MessageContext.CHARACTER_SET_ENCODING, "utf-16");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP, false);
- OMElement resultElem = call.invokeBlocking(operationName
- .getLocalPart(), payload);
-
+ OMElement resultElem = call.invokeBlocking(operationName.getLocalPart(), payload);
assertNotNull("Result is null", resultElem);
@@ -122,6 +123,7 @@
public void testStringWithRawEntities() throws Exception {
runTest("&<>'\"", "&<>'\"");
}
+
public void testStringWithLeadingAndTrailingSpaces() throws Exception {
runtest(" centered ");
}
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/CommonsHTTPEchoRawXMLTest.java Wed Nov 30 00:23:02 2005
@@ -21,6 +21,8 @@
import junit.framework.TestCase;
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.description.AxisService;
@@ -68,13 +70,13 @@
public void testEchoXMLASync() throws Exception {
OMElement payload = TestingUtils.createDummyOMElement();
- org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
+ Call call = new Call(
Constants.TESTING_PATH + "commons-http-enabledRepository");
-
- call.setTo(targetEPR);
-// call.setWsaAction(operationName.getLocalPart());
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -113,11 +115,13 @@
SOAPFactory fac = OMAbstractFactory.getSOAP11Factory();
OMElement payload = TestingUtils.createDummyOMElement();
- org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
+ Call call = new Call(
Constants.TESTING_PATH + "commons-http-enabledRepository");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java Wed Nov 30 00:23:02 2005
@@ -20,6 +20,8 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.util.TestConstants;
import org.apache.axis2.integration.TestingUtils;
@@ -42,6 +44,7 @@
private AxisService service;
private boolean finish = false;
+ private static final String CLIENT_HOME = Constants.TESTING_PATH + "chuncked-enabledRepository";
public EchoRawXMLChunckedTest() {
super(EchoRawXMLChunckedTest.class.getName());
@@ -52,7 +55,7 @@
}
protected void setUp() throws Exception {
- UtilServer.start(Constants.TESTING_PATH + "chuncked-enabledRepository");
+ UtilServer.start(CLIENT_HOME);
service =
Utils.createSimpleService(serviceName,
Echo.class.getName(),
@@ -110,14 +113,14 @@
OMElement payload = TestingUtils.createDummyOMElement();
- org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
- Constants.TESTING_PATH + "chuncked-enabledRepository");
+ Options clientOptions = new Options();
+ Call call = new Call(CLIENT_HOME);
+ call.setClientOptions(clientOptions);
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
- Constants.TRANSPORT_HTTP,
+ clientOptions.setTo(targetEPR);
+ clientOptions.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP,
false);
-
+
OMElement result =
call.invokeBlocking(operationName.getLocalPart(),
payload);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLLoadTest.java Wed Nov 30 00:23:02 2005
@@ -20,6 +20,7 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.util.TestConstants;
@@ -117,8 +118,10 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLMultipleTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLMultipleTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLMultipleTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLMultipleTest.java Wed Nov 30 00:23:02 2005
@@ -18,6 +18,7 @@
import junit.framework.TestCase;
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.context.MessageContext;
@@ -80,9 +81,10 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call(
"target/test-resources/intregrationRepo");
-
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -126,9 +128,10 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call(
"target/test-resources/intregrationRepo");
-
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
true);
@@ -173,9 +176,10 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call(
"target/test-resources/intregrationRepo");
-
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -195,8 +199,10 @@
new org.apache.axis2.client.Call(
"target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
true);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsSyncTest.java Wed Nov 30 00:23:02 2005
@@ -18,6 +18,7 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.ServiceContext;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.util.TestConstants;
@@ -86,13 +87,14 @@
org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
serviceContext);
- call.setTo(targetEPR);
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
call.engageModule(new QName(Constants.MODULE_ADDRESSING));
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
true);
- call.setWsaAction(operationName.getLocalPart());
-// call.setTimeOutInMilliSeconds(60*10000);
+ options.setAction(operationName.getLocalPart());
OMElement result = call.invokeBlocking(
operationName.getLocalPart(), method);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLOnTwoChannelsTest.java Wed Nov 30 00:23:02 2005
@@ -20,6 +20,7 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.context.ServiceContext;
@@ -94,11 +95,14 @@
call.engageModule(new QName(Constants.MODULE_ADDRESSING));
try {
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
true);
- call.setWsaAction(operationName.getLocalPart());
+ options.setAction(operationName.getLocalPart());
+ call.setClientOptions(options);
+
Callback callback = new Callback() {
public void onComplete(AsyncResult result) {
TestingUtils.campareWithCreatedOMElement(
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLTest.java Wed Nov 30 00:23:02 2005
@@ -22,6 +22,7 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.context.MessageContext;
@@ -51,7 +52,7 @@
protected AxisService service;
protected boolean finish = false;
-
+
public EchoRawXMLTest() {
super(EchoRawXMLTest.class.getName());
}
@@ -82,8 +83,10 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -126,8 +129,10 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -144,9 +149,10 @@
Call call =
new Call("target/test-resources/intregrationRepo");
-
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/FaultHandlingTest.java Wed Nov 30 00:23:02 2005
@@ -19,6 +19,7 @@
import junit.framework.TestCase;
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Options;
import org.apache.axis2.engine.util.MyInOutMEPClient;
import org.apache.axis2.engine.util.TestConstants;
import org.apache.axis2.integration.UtilServer;
@@ -49,8 +50,8 @@
private boolean finish = false;
protected void setUp() throws Exception {
- UtilServer.start();
- inOutMEPClient = getMyInOutMEPClient();
+ UtilServer.start();
+ inOutMEPClient = getMyInOutMEPClient();
}
public void testTwoHeadersSOAPMessage() throws AxisFault, XMLStreamException {
@@ -92,8 +93,8 @@
}
private SOAPEnvelope getResponse(SOAPEnvelope inEnvelope) throws AxisFault {
- inOutMEPClient.setExceptionToBeThrownOnSOAPFault(false);
- return inOutMEPClient.invokeBlockingWithEnvelopeOut(operationName.getLocalPart(), inEnvelope);
+ inOutMEPClient.getClientOptions().setExceptionToBeThrownOnSOAPFault(false);
+ return inOutMEPClient.invokeBlockingWithEnvelopeOut(operationName.getLocalPart(), inEnvelope);
}
private SOAPEnvelope getTwoHeadersSOAPEnvelope(SOAPFactory fac) {
@@ -106,9 +107,11 @@
private MyInOutMEPClient getMyInOutMEPClient() throws AxisFault {
MyInOutMEPClient inOutMEPClient = new MyInOutMEPClient("target/test-resources/intregrationRepo");
- inOutMEPClient.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
- inOutMEPClient.setTo(targetEPR);
- inOutMEPClient.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ inOutMEPClient.setClientOptions(options);
+ options.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
return inOutMEPClient;
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/HandlerFailureTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/HandlerFailureTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/HandlerFailureTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/HandlerFailureTest.java Wed Nov 30 00:23:02 2005
@@ -21,10 +21,10 @@
import junit.framework.TestCase;
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisService;
-import org.apache.axis2.description.Flow;
-import org.apache.axis2.description.FlowImpl;
import org.apache.axis2.engine.util.TestConstants;
import org.apache.axis2.handlers.AbstractHandler;
import org.apache.axis2.integration.UtilServer;
@@ -151,14 +151,17 @@
value.setText("Isaac Assimov, the foundation Sega");
method.addChild(value);
- org.apache.axis2.client.Call call =
- new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- //EndpointReference targetEPR = new EndpointReference(AddressingConstants.WSA_TO, "http://127.0.0.1:" + Utils.TESTING_PORT + "/axis/services/EchoXMLService");
+ String clientHome = "target/test-resources/intregrationRepo";
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
- call.setTo(targetEPR);
+ options.setTo(targetEPR);
+
+ Call call = new Call(clientHome);
+ call.setClientOptions(options);
+
OMElement result = call.invokeBlocking(
operationName.getLocalPart(), method);
result.serializeAndConsume(XMLOutputFactory.newInstance().createXMLStreamWriter(
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/MessageContextInjectionTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/MessageContextInjectionTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/MessageContextInjectionTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/MessageContextInjectionTest.java Wed Nov 30 00:23:02 2005
@@ -19,6 +19,7 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
import org.apache.axis2.client.MessageSender;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisOperation;
@@ -43,6 +44,7 @@
import org.apache.commons.logging.LogFactory;
import javax.xml.namespace.QName;
+
public class MessageContextInjectionTest extends TestCase implements TestConstants {
private Log log = LogFactory.getLog(getClass());
@@ -64,15 +66,15 @@
}
protected void setUp() throws Exception {
- AxisConfiguration config = new AxisConfigurationImpl();
+ AxisConfiguration config = new AxisConfigurationImpl();
TransportInDescription tIn = new TransportInDescription(new QName(Constants.TRANSPORT_LOCAL));
config.addTransportIn(tIn);
TransportOutDescription tOut = new TransportOutDescription(new QName(Constants.TRANSPORT_LOCAL));
config.addTransportOut(tOut);
-
- ((AxisConfigurationImpl)config).setDefaultDispatchers();
+
+ ((AxisConfigurationImpl) config).setDefaultDispatchers();
LocalTransportReceiver.CONFIG_CONTEXT = new ConfigurationContext(
config);
@@ -114,9 +116,12 @@
MessageSender sender = new MessageSender("target/test-resources/intregrationRepo");
- sender.setTo(targetEPR);
- sender.setSenderTransport(Constants.TRANSPORT_LOCAL);
- sender.setSoapVersionURI(SOAP11Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+ Options options = new Options();
+ sender.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setSenderTransportProtocol(Constants.TRANSPORT_LOCAL);
+ options.setSoapVersionURI(SOAP11Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+
sender.send(operationName.getLocalPart(), payload);
}
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/OneWayRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/OneWayRawXMLTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/OneWayRawXMLTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/OneWayRawXMLTest.java Wed Nov 30 00:23:02 2005
@@ -22,6 +22,7 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.client.MessageSender;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.description.AxisOperation;
import org.apache.axis2.description.AxisService;
@@ -83,8 +84,10 @@
MessageSender sender = new MessageSender("target/test-resources/intregrationRepo");
- sender.setTo(targetEPR);
- sender.setSenderTransport(Constants.TRANSPORT_HTTP);
+ Options options = new Options();
+ sender.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setSenderTransportProtocol(Constants.TRANSPORT_HTTP);
sender.send(operationName.getLocalPart(), payload);
int index = 0;
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/SOAPversionTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/SOAPversionTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/SOAPversionTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/SOAPversionTest.java Wed Nov 30 00:23:02 2005
@@ -19,6 +19,7 @@
import junit.framework.TestCase;
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Options;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.util.MyInOutMEPClient;
import org.apache.axis2.engine.util.TestConstants;
@@ -68,10 +69,12 @@
OMElement payload = createEnvelope();
MyInOutMEPClient inOutMEPClient = new MyInOutMEPClient("target/test-resources/intregrationRepo");
- inOutMEPClient.setSoapVersionURI(
+ Options options = new Options();
+ inOutMEPClient.setClientOptions(options);
+ options.setSoapVersionURI(
SOAP11Constants.SOAP_ENVELOPE_NAMESPACE_URI);
- inOutMEPClient.setTo(targetEPR);
- inOutMEPClient.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -89,10 +92,12 @@
OMElement payload = createEnvelope();
MyInOutMEPClient inOutMEPClient = new MyInOutMEPClient("target/test-resources/intregrationRepo");
- inOutMEPClient.setSoapVersionURI(
+ Options options = new Options();
+ inOutMEPClient.setClientOptions(options);
+ options.setSoapVersionURI(
SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
- inOutMEPClient.setTo(targetEPR);
- inOutMEPClient.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -112,11 +117,13 @@
OMElement payload = createEnvelope();
MyInOutMEPClient inOutMEPClient = new MyInOutMEPClient("target/test-resources/intregrationRepo");
- inOutMEPClient.setSoapVersionURI(
+ Options options = new Options();
+ inOutMEPClient.setClientOptions(options);
+ options.setSoapVersionURI(
SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
- inOutMEPClient.setTo(targetEPR);
- inOutMEPClient.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceDispatchingTest.java Wed Nov 30 00:23:02 2005
@@ -21,6 +21,7 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
+import org.apache.axis2.client.Options;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.util.TestConstants;
import org.apache.axis2.integration.TestingUtils;
@@ -71,9 +72,11 @@
OMElement payload = TestingUtils.createDummyOMElement();
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(
new EndpointReference("http://127.0.0.1:5555/axis/services/EchoXMLService/echoOMElement"));
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
OMElement result = call.invokeBlocking(
@@ -92,12 +95,14 @@
payload.addChild(value);
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(
new EndpointReference("http://127.0.0.1:5555/axis/services/EchoXMLService/"));
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
- call.setSoapAction("echoOMElement");
+ options.setSoapAction("echoOMElement");
OMElement result = call.invokeBlocking(
operationName.getLocalPart(), payload);
TestingUtils.campareWithCreatedOMElement(result);
@@ -118,9 +123,11 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(
new EndpointReference("http://127.0.0.1:5555/axis/services/"));
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
OMElement result = call.invokeBlocking(
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceGroupContextTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceGroupContextTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceGroupContextTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/ServiceGroupContextTest.java Wed Nov 30 00:23:02 2005
@@ -3,6 +3,7 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
+import org.apache.axis2.client.Options;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.util.RequestCounter;
import org.apache.axis2.engine.util.RequestCounterMessageReceiver;
@@ -35,6 +36,7 @@
*
* @author : Eran Chinthaka (chinthaka@apache.org)
*/
+
public class ServiceGroupContextTest extends TestCase {
/**
@@ -47,13 +49,13 @@
* Server will correctly identify the service group from the information sent by the client and
* retrieve the sgc earlier used and will use that for the current request as well.
* The service will retrieve the request count from the sgc and increase that by one.
- *
+ * <p/>
* Test will asserts whether the client gets the number of requests as 2, when he invokes two times.
*/
protected EndpointReference targetEPR = new EndpointReference("http://127.0.0.1:" +
- (UtilServer.TESTING_PORT) +
- "/axis/services/RequestCounter");
+ (UtilServer.TESTING_PORT) +
+ "/axis/services/RequestCounter");
protected Log log = LogFactory.getLog(getClass());
protected QName serviceName = new QName("RequestCounter");
protected QName operationName = new QName("getRequestCount");
@@ -63,7 +65,7 @@
protected void setUp() throws Exception {
UtilServer.start();
service = Utils.createSimpleService(serviceName, new RequestCounterMessageReceiver(),
- RequestCounter.class.getName(), operationName);
+ RequestCounter.class.getName(), operationName);
UtilServer.deployService(service);
}
@@ -80,18 +82,20 @@
org.apache.axis2.client.Call call = new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
- call.setWsaAction(operationName.getLocalPart());
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP, false);
+ options.setAction(operationName.getLocalPart());
SOAPEnvelope result = call.invokeBlocking(operationName.getLocalPart(), payload);
OMNamespace axis2Namespace = fac.createOMNamespace(Constants.AXIS2_NAMESPACE_URI,
- Constants.AXIS2_NAMESPACE_PREFIX);
+ Constants.AXIS2_NAMESPACE_PREFIX);
SOAPEnvelope defaultEnvelope = fac.getDefaultEnvelope();
SOAPHeaderBlock soapHeaderBlock = defaultEnvelope.getHeader().addHeaderBlock(Constants.SERVICE_GROUP_ID,
- axis2Namespace);
+ axis2Namespace);
System.out.println("soapHeaderBlock = " + soapHeaderBlock);
String serviceGroupId = result.getHeader().getFirstChildWithName(new QName("ReplyTo"))
@@ -101,7 +105,7 @@
soapHeaderBlock.setText(serviceGroupId);
SOAPEnvelope soapEnvelope = call.invokeBlocking(operationName.getLocalPart(),
- defaultEnvelope);
+ defaultEnvelope);
String text = soapEnvelope.getBody().getFirstElement().getText();
assertEquals("Number of requests should be 2", 2, Integer.parseInt(text));
}
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/util/InvokerThread.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/util/InvokerThread.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/util/InvokerThread.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/engine/util/InvokerThread.java Wed Nov 30 00:23:02 2005
@@ -4,6 +4,7 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.integration.TestingUtils;
import org.apache.axis2.integration.UtilServer;
import org.apache.axis2.om.OMElement;
@@ -52,10 +53,12 @@
new Call("target/test-resources/intregrationRepo");
OMElement payload = TestingUtils.createDummyOMElement();
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
+ call.setClientOptions(options);
OMElement result =
call.invokeBlocking(operationName.getLocalPart(),
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/groovy/GroovyServiceTest.java Wed Nov 30 00:23:02 2005
@@ -19,6 +19,8 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
+import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.EchoRawXMLTest;
import org.apache.axis2.integration.UtilServer;
@@ -40,8 +42,8 @@
private EndpointReference targetEPR =
new EndpointReference("http://127.0.0.1:"
- + (UtilServer.TESTING_PORT)
- + "/axis/services/groovyService/echo");
+ + (UtilServer.TESTING_PORT)
+ + "/axis/services/groovyService/echo");
private QName serviceName = new QName("groovyService");
private QName operationName = new QName("echo");
@@ -79,20 +81,23 @@
//OMElement payload = createPayLoad();
OMElement payload = getpayLoad();
- org.apache.axis2.client.Call call =
- new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
+ Call call =
+ new Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
- call.setWsaAction(operationName.getLocalPart());
+ options.setAction(operationName.getLocalPart());
+
+ call.setClientOptions(options);
OMElement result = call.invokeBlocking(operationName.getLocalPart(),
payload);
assertNotNull(result);
- OMElement person = (OMElement)result.getFirstOMChild();
- assertEquals(person.getLocalName(),"person");
+ OMElement person = (OMElement) result.getFirstOMChild();
+ assertEquals(person.getLocalName(), "person");
StringWriter writer = new StringWriter();
result.build();
@@ -102,21 +107,20 @@
}
-
private OMElement getpayLoad() throws XMLStreamException {
- String str= "<ADDRESS><DET><NAME>Ponnampalam Thayaparan</NAME> <OCC>Student</OCC>" +
+ String str = "<ADDRESS><DET><NAME>Ponnampalam Thayaparan</NAME> <OCC>Student</OCC>" +
"<ADD>3-2/1,Hudson Road,Colombo-03</ADD><GENDER>Male</GENDER>" +
"</DET><DET><NAME>Eranka Samaraweera</NAME><OCC>Student</OCC><ADD>Martara</ADD>" +
"<GENDER>Male</GENDER></DET><DET><NAME>Sriskantharaja Ahilan</NAME>" +
"<OCC>Student</OCC><ADD>Trincomalee</ADD><GENDER>Male</GENDER>" +
"</DET></ADDRESS>";
- XMLStreamReader xmlReader= XMLInputFactory.newInstance().createXMLStreamReader(new
+ XMLStreamReader xmlReader = XMLInputFactory.newInstance().createXMLStreamReader(new
ByteArrayInputStream(str.getBytes()));
OMFactory fac = OMAbstractFactory.getOMFactory();
StAXOMBuilder staxOMBuilder = new
- StAXOMBuilder(fac,xmlReader);
- return staxOMBuilder.getDocumentElement();
+ StAXOMBuilder(fac, xmlReader);
+ return staxOMBuilder.getDocumentElement();
}
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailCharSetEncodingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailCharSetEncodingTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailCharSetEncodingTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailCharSetEncodingTest.java Wed Nov 30 00:23:02 2005
@@ -20,6 +20,7 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.context.ConfigurationContext;
@@ -126,8 +127,10 @@
org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
clientServiceContext);
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_MAIL,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_MAIL,
Constants.TRANSPORT_MAIL, true);
Callback callback = new Callback() {
public void onComplete(AsyncResult result) {
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailOneWayRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailOneWayRawXMLTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailOneWayRawXMLTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailOneWayRawXMLTest.java Wed Nov 30 00:23:02 2005
@@ -23,6 +23,7 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.client.MessageSender;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.ConfigurationContext;
import org.apache.axis2.context.MessageContext;
import org.apache.axis2.context.ServiceContext;
@@ -126,8 +127,9 @@
MessageSender sender = new MessageSender(serviceContext);
- sender.setTo(targetEPR);
- sender.setSenderTransport(Constants.TRANSPORT_MAIL);
+ Options options = new Options();
+ options.setTo(targetEPR);
+ options.setSenderTransportProtocol(Constants.TRANSPORT_MAIL);
sender.send(operationName.getLocalPart(), payload);
int index = 0;
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailRequestResponseRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailRequestResponseRawXMLTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailRequestResponseRawXMLTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailRequestResponseRawXMLTest.java Wed Nov 30 00:23:02 2005
@@ -22,6 +22,7 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.context.ConfigurationContext;
@@ -128,12 +129,14 @@
org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
serviceContext);
-// call.engageModule(new QName(Constants.MODULE_ADDRESSING));
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_MAIL,
+ Options options = new Options();
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_MAIL,
Constants.TRANSPORT_MAIL,
true);
+ call.setClientOptions(options);
+
Callback callback = new Callback() {
public void onComplete(AsyncResult result) {
try {
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailetRequestResponceRawXMLTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailetRequestResponceRawXMLTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailetRequestResponceRawXMLTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mail/MailetRequestResponceRawXMLTest.java Wed Nov 30 00:23:02 2005
@@ -21,6 +21,7 @@
import org.apache.axis2.AxisFault;
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.context.ConfigurationContext;
@@ -125,12 +126,12 @@
org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
serviceContext);
-// call.engageModule(new QName(Constants.MODULE_ADDRESSING));
-
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_MAIL,
+ Options options = new Options();
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_MAIL,
Constants.TRANSPORT_MAIL,
true);
+ call.setClientOptions(options);
Callback callback = new Callback() {
public void onComplete(AsyncResult result) {
try {
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMCommonsChunkingTest.java Wed Nov 30 00:23:02 2005
@@ -20,6 +20,7 @@
import org.apache.axis2.Constants;
import org.apache.axis2.attachments.utils.ImageDataSource;
import org.apache.axis2.attachments.utils.ImageIO;
+import org.apache.axis2.client.Options;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.Echo;
import org.apache.axis2.engine.util.TestConstants;
@@ -99,11 +100,13 @@
org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
Constants.TESTING_PATH + "commons-http-enabledRepository");
- call.setTo(targetEPR);
- call.set(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setProperty(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP, false);
- call.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+ options.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
OMElement result = call.invokeBlocking(operationName
.getLocalPart(), payload);
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMLoadTest.java Wed Nov 30 00:23:02 2005
@@ -18,6 +18,7 @@
import junit.framework.TestCase;
import org.apache.axis2.Constants;
+import org.apache.axis2.client.Options;
import org.apache.axis2.context.ServiceContext;
import org.apache.axis2.description.AxisService;
import org.apache.axis2.engine.Echo;
@@ -82,7 +83,7 @@
98};
for (int i = 0; i < 4; i++) {
OMElement subData = fac.createOMElement("subData", omNs);
- DataHandler dataHandler = new DataHandler("Thilina","text/plain");
+ DataHandler dataHandler = new DataHandler("Thilina", "text/plain");
//new ByteArrayDataSource(expectedByteArray));
textData = new OMTextImpl(dataHandler, true);
subData.addChild(textData);
@@ -102,12 +103,15 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.set(Constants.Configuration.ENABLE_MTOM,
+
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setProperty(Constants.Configuration.ENABLE_MTOM,
Constants.VALUE_TRUE);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP, false);
- call.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+ options.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
OMElement result = call.invokeBlocking(operationName
.getLocalPart(),
@@ -120,9 +124,9 @@
UtilServer.unDeployClientService();
}
}
- protected void compareWithActualOMText(OMText binaryNode)
- {
- assertEquals(textData.getText(),binaryNode.getText());
+
+ protected void compareWithActualOMText(OMText binaryNode) {
+ assertEquals(textData.getText(), binaryNode.getText());
}
}
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMTest.java Wed Nov 30 00:23:02 2005
@@ -21,6 +21,7 @@
import org.apache.axis2.Constants;
import org.apache.axis2.attachments.utils.ImageDataSource;
import org.apache.axis2.attachments.utils.ImageIO;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.context.ServiceContext;
@@ -105,8 +106,10 @@
org.apache.axis2.client.Call call = new org.apache.axis2.client.Call(
"target/test-resources/intregrationRepo" );
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP,
false);
@@ -150,11 +153,14 @@
org.apache.axis2.client.Call call =
new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
- call.setTo(targetEPR);
- call.set(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+
+ Options options = new Options();
+ call.setClientOptions(options);
+ options.setTo(targetEPR);
+ options.setProperty(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
+ options.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP, false);
- call.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+ options.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
OMElement result = call.invokeBlocking(operationName
.getLocalPart(),
Modified: webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java?rev=349908&r1=349907&r2=349908&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java (original)
+++ webservices/axis2/trunk/java/modules/integration/test/org/apache/axis2/mtom/EchoRawMTOMToBase64Test.java Wed Nov 30 00:23:02 2005
@@ -21,6 +21,8 @@
import org.apache.axis2.Constants;
import org.apache.axis2.addressing.EndpointReference;
import org.apache.axis2.attachments.ByteArrayDataSource;
+import org.apache.axis2.client.Call;
+import org.apache.axis2.client.Options;
import org.apache.axis2.client.async.AsyncResult;
import org.apache.axis2.client.async.Callback;
import org.apache.axis2.description.AxisService;
@@ -98,15 +100,17 @@
public void testEchoXMLASync() throws Exception {
OMElement payload = createPayload();
- org.apache.axis2.client.Call call =
- new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
+ String clientHome = "target/test-resources/intregrationRepo";
-
- call.setTo(targetEPR);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
- Constants.TRANSPORT_HTTP,
+ Options clientOptions = new Options();
+ clientOptions.setTo(targetEPR);
+ clientOptions.setTransportInfo(Constants.TRANSPORT_HTTP, Constants.TRANSPORT_HTTP,
false);
+ Call call = new Call(clientHome);
+ call.setClientOptions(clientOptions);
+
+
Callback callback = new Callback() {
public void onComplete(AsyncResult result) {
SOAPEnvelope envelope = result.getResponseEnvelope();
@@ -143,15 +147,19 @@
OMElement payload = createPayload();
- org.apache.axis2.client.Call call =
- new org.apache.axis2.client.Call("target/test-resources/intregrationRepo");
+ String clientHome = "target/test-resources/intregrationRepo";
- call.setTo(targetEPR);
- call.set(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
- call.setTransportInfo(Constants.TRANSPORT_HTTP,
+ Options clientOptions = new Options();
+ clientOptions.setTo(targetEPR);
+ clientOptions.setProperty(Constants.Configuration.ENABLE_MTOM, Constants.VALUE_TRUE);
+ clientOptions.setTransportInfo(Constants.TRANSPORT_HTTP,
Constants.TRANSPORT_HTTP, false);
- call.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+ clientOptions.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
+ Call call =
+ new Call(clientHome);
+ call.setClientOptions(clientOptions);
+
OMElement result = call.invokeBlocking(operationName
.getLocalPart(), payload);