DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8426>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8426 Axis client can not access .Net Web Service ------- Additional Comments From [EMAIL PROTECTED] 2002-04-23 21:28 ------- I am using a Call directly, but not setting a SOAPActionURI. Here is the code for it: public class MSTempConvClient { public static void main(String [] args) throws Exception { Options options = new Options(args); String endpoint = "http://localhost:" + options.getPort() + "/TempConvert1/Service1.asmx"; args = options.getRemainingArgs(); if (args == null || args.length != 2) { System.err.println("Usage: TempConvClient <conv> arg1"); return; } String method = args[0]; if (!(method.equals("ConvertTemperature"))) { System.err.println("Usage: CalcClient <conv> arg1 "); return; } Double d1 = new Double(args[1]); Service service = new Service(); Call call = (Call) service.createCall(); call.setTargetEndpointAddress( new java.net.URL(endpoint) ); call.setOperationName( method ); call.addParameter( "op1", XMLType.XSD_INT, ParameterMode.PARAM_MODE_IN ); //call.addParameter( "op2", XMLType.XSD_INT, ParameterMode.PARAM_MODE_IN ); call.setReturnType( XMLType.XSD_INT ); Double ret = (Double)(call.invoke( new Object [] { d1}) ); System.out.println("Got result : " + ret); } } 1- Is this URI the same as the end point in the Call 2- Are there any other things need to be set in the SOAP call? I am not finding explanation of all that, other than in the API doc, which does not explain what is needed and what is optional; very cryptic. Thanks I am enclosing here the service wsdl for reference: --------------------------------------------------- <?xml version="1.0" encoding="utf-8"?> <definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:s0="http://Walkthrough/XmlWebServices/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" targetNamespace="http://Walkthrough/XmlWebServices/" xmlns="http://schemas.xmlsoap.org/wsdl/"> <types> <s:schema elementFormDefault="qualified" targetNamespace="http://Walkthrough/XmlWebServices/"> <s:element name="ConvertTemperature"> <s:complexType> <s:sequence> <s:element minOccurs="1" maxOccurs="1" name="dFahrenheit" type="s:double" /> </s:sequence> </s:complexType> </s:element> <s:element name="ConvertTemperatureResponse"> <s:complexType> <s:sequence> <s:element minOccurs="1" maxOccurs="1" name="ConvertTemperatureResult" type="s:double" /> </s:sequence> </s:complexType> </s:element> <s:element name="double" type="s:double" /> </s:schema> </types> <message name="ConvertTemperatureSoapIn"> <part name="parameters" element="s0:ConvertTemperature" /> </message> <message name="ConvertTemperatureSoapOut"> <part name="parameters" element="s0:ConvertTemperatureResponse" /> </message> <message name="ConvertTemperatureHttpGetIn"> <part name="dFahrenheit" type="s:string" /> </message> <message name="ConvertTemperatureHttpGetOut"> <part name="Body" element="s0:double" /> </message> <message name="ConvertTemperatureHttpPostIn"> <part name="dFahrenheit" type="s:string" /> </message> <message name="ConvertTemperatureHttpPostOut"> <part name="Body" element="s0:double" /> </message> <portType name="Service1Soap"> <operation name="ConvertTemperature"> <documentation>This method converts a temperature in degrees Fahrenheit to a temperature in degrees Celsius.</documentation> <input message="s0:ConvertTemperatureSoapIn" /> <output message="s0:ConvertTemperatureSoapOut" /> </operation> </portType> <portType name="Service1HttpGet"> <operation name="ConvertTemperature"> <documentation>This method converts a temperature in degrees Fahrenheit to a temperature in degrees Celsius.</documentation> <input message="s0:ConvertTemperatureHttpGetIn" /> <output message="s0:ConvertTemperatureHttpGetOut" /> </operation> </portType> <portType name="Service1HttpPost"> <operation name="ConvertTemperature"> <documentation>This method converts a temperature in degrees Fahrenheit to a temperature in degrees Celsius.</documentation> <input message="s0:ConvertTemperatureHttpPostIn" /> <output message="s0:ConvertTemperatureHttpPostOut" /> </operation> </portType> <binding name="Service1Soap" type="s0:Service1Soap"> <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" /> <operation name="ConvertTemperature"> <soap:operation soapAction="http://Walkthrough/XmlWebServices/ConvertTemperature" style="document" /> <input> <soap:body use="literal" /> </input> <output> <soap:body use="literal" /> </output> </operation> </binding> <binding name="Service1HttpGet" type="s0:Service1HttpGet"> <http:binding verb="GET" /> <operation name="ConvertTemperature"> <http:operation location="/ConvertTemperature" /> <input> <http:urlEncoded /> </input> <output> <mime:mimeXml part="Body" /> </output> </operation> </binding> <binding name="Service1HttpPost" type="s0:Service1HttpPost"> <http:binding verb="POST" /> <operation name="ConvertTemperature"> <http:operation location="/ConvertTemperature" /> <input> <mime:content type="application/x-www-form-urlencoded" /> </input> <output> <mime:mimeXml part="Body" /> </output> </operation> </binding> <service name="Service1"> <documentation>A temprature conversion service.</documentation> <port name="Service1Soap" binding="s0:Service1Soap"> <soap:address location="http://localhost/TempConvert1/Service1.asmx" /> </port> <port name="Service1HttpGet" binding="s0:Service1HttpGet"> <http:address location="http://localhost/TempConvert1/Service1.asmx" /> </port> <port name="Service1HttpPost" binding="s0:Service1HttpPost"> <http:address location="http://localhost/TempConvert1/Service1.asmx" /> </port> </service> </definitions>