1 Reply Latest reply on Sep 8, 2006 10:09 AM by alan Jones

    Java Web Service from a .NET generated WSDL

    alan Jones Newbie

      OK, some of you will have seen the problem I posted about here: http://jboss.org/index.html?module=bb&op=viewtopic&t=89498 regarding an encoding problem I was having with a web service we were developing.

      After some investigation, I think I may have narrowed down the problem. The web service is a Java web service deployed onto JBossAS 4.0.4 GA The client will eventually be a .NET client, but we have the same problem using our test client which is written in Java.

      Now, I think the problem may be coming from the WSDL file we are using, which was generated by our supplier from .NET code. We are using wscompile to generate the web service from the WSDL they have supplied us. From what I've read, there can be some interoperability problems between .NET and Java.

      Could someone with a little more knowledge than me have a scan over the following WSDL for me please and see if there is anything that would cause a problem when fed into the wscompile tool. I know the WSDL is correct, as another client of our supplier uses it fine in their .NET web service, but we are the first to use it for a Java Web Service:

      <?xml version="1.0" encoding="utf-8"?>
      <wsdl: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:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
       xmlns:tns="http://domainname.co.uk/sysname/grpname/V1.0"
      xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
      targetNamespace="http://domainname.co.uk/sysname/grpname/V1.0"
       xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
       <wsdl:types>
       <s:schema elementFormDefault="qualified" targetNamespace="http://domainname.co.uk/sysname/grpname/V1.0">
       <s:element name="TransactionStatusUpdate">
       <s:complexType>
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="request" type="tns:TransactionUpdateMsg" />
       </s:sequence>
       </s:complexType>
       </s:element>
       <s:complexType name="TransactionUpdateMsg">
       <s:sequence>
       <s:element minOccurs="1" maxOccurs="1" name="TransactionId" type="s:int" />
       <s:element minOccurs="1" maxOccurs="1" name="Status" type="s:int" />
       <s:element minOccurs="0" maxOccurs="1" name="Description" type="s:string" />
       <s:element minOccurs="1" maxOccurs="1" name="UTCTimestamp" type="s:dateTime" />
       </s:sequence>
       </s:complexType>
       <s:element name="TransactionStatusUpdateResponse">
       <s:complexType>
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="TransactionStatusUpdateResult" type="tns:ABCResponseMsg" />
       </s:sequence>
       </s:complexType>
       </s:element>
       <s:complexType name="ABCResponseMsg">
       <s:sequence>
       <s:element minOccurs="1" maxOccurs="1" name="Accepted" type="s:boolean" />
       <s:element minOccurs="1" maxOccurs="1" name="UTCTimestamp" type="s:dateTime" />
       </s:sequence>
       </s:complexType>
       <s:element name="XyzBusinessResponse">
       <s:complexType>
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="XyzBusinessResponseRequest" type="tns:XyzBusinessResponse" />
       </s:sequence>
       </s:complexType>
       </s:element>
       <s:complexType name="XyzBusinessResponse">
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="Payload" type="s:string" />
       <s:element minOccurs="1" maxOccurs="1" name="UTCTimestamp" type="s:dateTime" />
       </s:sequence>
       </s:complexType>
       <s:element name="XyzBusinessResponseResponse">
       <s:complexType>
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="XyzBusinessResponseResult" type="tns:ABCResponseMsg" />
       </s:sequence>
       </s:complexType>
       </s:element>
       <s:element name="MainSystemResults">
       <s:complexType>
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="MainSystemResultsRequest" type="tns:MainSystemResults" />
       </s:sequence>
       </s:complexType>
       </s:element>
       <s:complexType name="MainSystemResults">
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="Payload" type="s:string" />
       <s:element minOccurs="1" maxOccurs="1" name="UTCTimestamp" type="s:dateTime" />
       </s:sequence>
       </s:complexType>
       <s:element name="MainSystemResultsResponse">
       <s:complexType>
       <s:sequence>
       <s:element minOccurs="0" maxOccurs="1" name="MainSystemResultsResult" type="tns:ABCResponseMsg" />
       </s:sequence>
       </s:complexType>
       </s:element>
       </s:schema>
       </wsdl:types>
       <wsdl:message name="TransactionStatusUpdateSoapIn">
       <wsdl:part name="parameters" element="tns:TransactionStatusUpdate" />
       </wsdl:message>
       <wsdl:message name="TransactionStatusUpdateSoapOut">
       <wsdl:part name="parameters" element="tns:TransactionStatusUpdateResponse" />
       </wsdl:message>
       <wsdl:message name="XyzBusinessResponseSoapIn">
       <wsdl:part name="parameters" element="tns:XyzBusinessResponse" />
       </wsdl:message>
       <wsdl:message name="XyzBusinessResponseSoapOut">
       <wsdl:part name="parameters" element="tns:XyzBusinessResponseResponse" />
       </wsdl:message>
       <wsdl:message name="MainSystemResultsSoapIn">
       <wsdl:part name="parameters" element="tns:MainSystemResults" />
       </wsdl:message>
       <wsdl:message name="MainSystemResultsSoapOut">
       <wsdl:part name="parameters" element="tns:MainSystemResultsResponse" />
       </wsdl:message>
       <wsdl:portType name="grpnameLfsServiceSoap">
       <wsdl:operation name="TransactionStatusUpdate">
       <wsdl:input message="tns:TransactionStatusUpdateSoapIn" />
       <wsdl:output message="tns:TransactionStatusUpdateSoapOut" />
       </wsdl:operation>
       <wsdl:operation name="XyzBusinessResponse">
       <wsdl:input message="tns:XyzBusinessResponseSoapIn" />
       <wsdl:output message="tns:XyzBusinessResponseSoapOut" />
       </wsdl:operation>
       <wsdl:operation name="MainSystemResults">
       <wsdl:input message="tns:MainSystemResultsSoapIn" />
       <wsdl:output message="tns:MainSystemResultsSoapOut" />
       </wsdl:operation>
       </wsdl:portType>
       <wsdl:binding name="grpnameLfsServiceSoap" type="tns:grpnameLfsServiceSoap">
       <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" />
       <wsdl:operation name="TransactionStatusUpdate">
       <soap:operation soapAction="http://domainname.co.uk/sysname/grpname/v1.0/LFSUpdate" style="document" />
       <wsdl:input>
       <soap:body use="literal" />
       </wsdl:input>
       <wsdl:output>
       <soap:body use="literal" />
       </wsdl:output>
       </wsdl:operation>
       <wsdl:operation name="XyzBusinessResponse">
       <soap:operation soapAction="http://domainname.co.uk/sysname/grpname/v1.0/LFSXyzBusinessResponse" style="document" />
       <wsdl:input>
       <soap:body use="literal" />
       </wsdl:input>
       <wsdl:output>
       <soap:body use="literal" />
       </wsdl:output>
       </wsdl:operation>
       <wsdl:operation name="MainSystemResults">
       <soap:operation soapAction="http://domainname.co.uk/sysname/grpname/v1.0/LFSMainSystemResults" style="document" />
       <wsdl:input>
       <soap:body use="literal" />
       </wsdl:input>
       <wsdl:output>
       <soap:body use="literal" />
       </wsdl:output>
       </wsdl:operation>
       </wsdl:binding>
       <wsdl:service name="grpnameLfsService">
       <wsdl:port name="grpnameLfsServiceSoap" binding="tns:grpnameLfsServiceSoap">
       <soap:address location="http://localhost/LFSTransactionUpdate/grpnameLfsService.asmx" />
       </wsdl:port>
       </wsdl:service>
      </wsdl:definitions>


      Is there another tool out there that we could use instead of wscompile that would generate the web service Java code for us in the same way, but without the problems we are seeing?