I am trying to understand how to best create a Web Service from a given Java
Interface.

I have 

 i) successfully created a wsdl with java2ws
 ii) deployed the web service to JBoss using the CXFServlet (removing
jbossws.sar)

=> now the WSDL generated with java2ws and the wsdl returned from ?wsdl
differ.
1) Why?

Then I tried to add the generated wsdl as wsdlLocation in cxf.xml.
Whenever I now call java2ws it complains that the file at wsdlLocation does
not exist.
But it is the file that I want to generate ...
2) Why is java2ws trying to find a WSDL that it just should generate?

Victor

--

JBOSS/CXFServlet WSDL:

<?xml version='1.0' encoding='UTF-8'?>
<wsdl:definitions name="TestWSImplService"
 targetNamespace="http://testws.artive.com/";
 xmlns:tns="http://testws.artive.com/";
 xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
 xmlns:xsd="http://www.w3.org/2001/XMLSchema";
 xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
 xmlns:ns1="http://cxf.apache.org/bindings/xformat";
 >
 <wsdl:types>
  <xsd:schema attributeFormDefault="unqualified"
   elementFormDefault="unqualified"
   targetNamespace="http://testws.artive.com/";
   xmlns:tns="http://testws.artive.com/";
   xmlns:xsd="http://www.w3.org/2001/XMLSchema";>
   <xsd:element name="message" type="tns:message" />
   <xsd:complexType name="message">
    <xsd:sequence />
   </xsd:complexType>
   <xsd:element name="messageResponse" type="tns:messageResponse" />
   <xsd:complexType name="messageResponse">
    <xsd:sequence>
     <xsd:element minOccurs="0" name="return" type="xsd:string" />
    </xsd:sequence>
   </xsd:complexType>
  </xsd:schema>
 </wsdl:types>
 <wsdl:message name="message">
  <wsdl:part element="tns:message" name="parameters"></wsdl:part>
 </wsdl:message>
 <wsdl:message name="messageResponse">
  <wsdl:part element="tns:messageResponse" name="parameters">
  </wsdl:part>
 </wsdl:message>
 <wsdl:portType name="TestWS">
  <wsdl:operation name="message">
   <wsdl:input message="tns:message" name="message"></wsdl:input>
   <wsdl:output message="tns:messageResponse" name="messageResponse">
   </wsdl:output>
  </wsdl:operation>
 </wsdl:portType>
 <wsdl:binding name="TestWSImplServiceSoapBinding" type="tns:TestWS">
  <soap:binding style="document"
   transport="http://schemas.xmlsoap.org/soap/http"; />
  <wsdl:operation name="message">
   <soap:operation soapAction="" style="document" />
   <wsdl:input name="message">
    <soap:body use="literal" />
   </wsdl:input>
   <wsdl:output name="messageResponse">
    <soap:body use="literal" />
   </wsdl:output>
  </wsdl:operation>
 </wsdl:binding>
 <wsdl:service name="TestWSImplService">
  <wsdl:port binding="tns:TestWSImplServiceSoapBinding"
   name="TestWSImplPort">
   <soap:address
    location="http://gn0alw0105:8080/testws/services/TestWS"; />
  </wsdl:port>
 </wsdl:service>
</wsdl:definitions>

<!-- ***************************************************************** -->
java2ws generated WSDL:

<?xml version='1.0' encoding='UTF-8'?>
<wsdl:definitions name="TestWSImpl"
 targetNamespace="http://testws.artive.com/";
 xmlns:tns="http://testws.artive.com/";
 xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
 xmlns:xsd="http://www.w3.org/2001/XMLSchema";
 xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
 >
 <wsdl:types>
  <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema";
   xmlns:tns="http://testws.artive.com/";
   attributeFormDefault="unqualified" elementFormDefault="qualified"
   targetNamespace="http://testws.artive.com/";>
   <xsd:element name="message" type="tns:message" />
   <xsd:complexType name="message">
    <xsd:sequence />
   </xsd:complexType>
   <xsd:element name="messageResponse" type="tns:messageResponse" />
   <xsd:complexType name="messageResponse">
    <xsd:sequence>
     <xsd:element minOccurs="0" name="return" type="xsd:string" />
    </xsd:sequence>
   </xsd:complexType>
  </xsd:schema>
 </wsdl:types>
 <wsdl:message name="message">
  <wsdl:part name="parameters" element="tns:message"></wsdl:part>
 </wsdl:message>
 <wsdl:message name="messageResponse">
  <wsdl:part name="parameters" element="tns:messageResponse">
  </wsdl:part>
 </wsdl:message>
 <wsdl:portType name="TestWSImplPortType">
  <wsdl:operation name="message">
   <wsdl:input name="message" message="tns:message"></wsdl:input>
   <wsdl:output name="messageResponse" message="tns:messageResponse">
   </wsdl:output>
  </wsdl:operation>
 </wsdl:portType>
 <wsdl:binding name="TestWSImplSoapBinding"
  type="tns:TestWSImplPortType">
  <soap:binding style="document"
   transport="http://schemas.xmlsoap.org/soap/http"; />
  <wsdl:operation name="message">
   <soap:operation soapAction="" style="document" />
   <wsdl:input name="message">
    <soap:body use="literal" />
   </wsdl:input>
   <wsdl:output name="messageResponse">
    <soap:body use="literal" />
   </wsdl:output>
  </wsdl:operation>
 </wsdl:binding>
 <wsdl:service name="TestWSImpl">
  <wsdl:port name="TestWSImplPort"
   binding="tns:TestWSImplSoapBinding">
   <soap:address location="http://localhost:9090/TestWSImplPort"; />
  </wsdl:port>
 </wsdl:service>
</wsdl:definitions>


-- 
View this message in context: 
http://www.nabble.com/java2ws-and-wsdlLocation-tp19775292p19775292.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to