Hi to all,

Just tried XFire 1.2.4 and still puzzled by WSDL generated from Pojos.

I took the CustomerService sample from 1.2.4 samples but moved the
Customer and UserToken from org.codehaus.xfire.demo to
org.codehaus.xfire.demo.datas.

Here is the WSDL generated by XFire 1.2.4 :

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="http://demo.xfire.codehaus.org";
xmlns:tns="http://demo.xfire.codehaus.org";
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/";
xmlns:soap12="http://www.w3.org/2003/05/soap-envelope";
xmlns:ns1="http://datas.demo.xfire.codehaus.org";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:soapenc11="http://schemas.xmlsoap.org/soap/encoding/";
xmlns:soapenc12="http://www.w3.org/2003/05/soap-encoding";
xmlns:soap11="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";>
 <wsdl:types>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema";
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://demo.xfire.codehaus.org";>
<xsd:element name="getCustomers">
<xsd:complexType/>
</xsd:element>
<xsd:element name="getCustomersResponse">
<xsd:complexType>
<xsd:sequence>
<xsd:element maxOccurs="1" minOccurs="1" name="Customers"
nillable="true" type="ns1:ArrayOfCustomer"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="addCustomer">
<xsd:complexType>
<xsd:sequence>
<xsd:element maxOccurs="1" minOccurs="1" name="customer"
nillable="true" type="ns1:Customer"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="addCustomerResponse">
<xsd:complexType>
<xsd:sequence>
<xsd:element maxOccurs="1" minOccurs="1" name="out" nillable="true"
type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="UserToken" type="ns1:UserToken"/>
</xsd:schema>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema";
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://datas.demo.xfire.codehaus.org";>
<xsd:complexType name="ArrayOfCustomer">
<xsd:sequence>
<xsd:element maxOccurs="unbounded" minOccurs="0" name="Customer"
nillable="true" type="ns1:Customer"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="Customer">
<xsd:sequence>
<xsd:element minOccurs="0" name="email" nillable="true" type="xsd:string"/>
<xsd:element minOccurs="0" name="name" nillable="true" type="xsd:string"/>
<xsd:element minOccurs="0" name="phone" nillable="true" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="UserToken">
<xsd:sequence>
<xsd:element minOccurs="0" name="password" nillable="true" type="xsd:string"/>
<xsd:element minOccurs="0" name="username" nillable="true" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
 </wsdl:types>
 <wsdl:message name="getCustomersRequest">
   <wsdl:part name="parameters" element="tns:getCustomers">
   </wsdl:part>
 </wsdl:message>
 <wsdl:message name="getCustomersRequestHeaders">
   <wsdl:part name="UserToken" element="tns:UserToken">
   </wsdl:part>
 </wsdl:message>
 <wsdl:message name="getCustomersResponse">
   <wsdl:part name="parameters" element="tns:getCustomersResponse">
   </wsdl:part>
 </wsdl:message>
 <wsdl:message name="addCustomerRequestHeaders">
   <wsdl:part name="UserToken" element="tns:UserToken">
   </wsdl:part>
 </wsdl:message>
 <wsdl:message name="addCustomerResponse">
   <wsdl:part name="parameters" element="tns:addCustomerResponse">
   </wsdl:part>
 </wsdl:message>
 <wsdl:message name="addCustomerRequest">
   <wsdl:part name="parameters" element="tns:addCustomer">
   </wsdl:part>
 </wsdl:message>
 <wsdl:portType name="CustomerServicePortType">
   <wsdl:operation name="getCustomers">
     <wsdl:input name="getCustomersRequest" message="tns:getCustomersRequest">
   </wsdl:input>
     <wsdl:output name="getCustomersResponse"
message="tns:getCustomersResponse">
   </wsdl:output>
   </wsdl:operation>
   <wsdl:operation name="addCustomer">
     <wsdl:input name="addCustomerRequest" message="tns:addCustomerRequest">
   </wsdl:input>
     <wsdl:output name="addCustomerResponse" message="tns:addCustomerResponse">
   </wsdl:output>
   </wsdl:operation>
 </wsdl:portType>
 <wsdl:binding name="CustomerServiceHttpBinding"
type="tns:CustomerServicePortType">
   <wsdlsoap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
   <wsdl:operation name="getCustomers">
     <wsdlsoap:operation soapAction=""/>
     <wsdl:input name="getCustomersRequest">
       <wsdlsoap:body use="literal"/>
       <wsdlsoap:header message="tns:getCustomersRequestHeaders"
part="UserToken" use="literal">
       </wsdlsoap:header>
     </wsdl:input>
     <wsdl:output name="getCustomersResponse">
       <wsdlsoap:body use="literal"/>
     </wsdl:output>
   </wsdl:operation>
   <wsdl:operation name="addCustomer">
     <wsdlsoap:operation soapAction=""/>
     <wsdl:input name="addCustomerRequest">
       <wsdlsoap:body use="literal"/>
       <wsdlsoap:header message="tns:addCustomerRequestHeaders"
part="UserToken" use="literal">
       </wsdlsoap:header>
     </wsdl:input>
     <wsdl:output name="addCustomerResponse">
       <wsdlsoap:body use="literal"/>
     </wsdl:output>
   </wsdl:operation>
 </wsdl:binding>
 <wsdl:service name="CustomerService">
   <wsdl:port name="CustomerServiceHttpPort"
binding="tns:CustomerServiceHttpBinding">
     <wsdlsoap:address
location="http://localhost:19991/test-soa/services/CustomerService"/>
   </wsdl:port>
 </wsdl:service>
</wsdl:definitions>


As usually Eclipse WTP WSDL explorer complains about reference to
Customer and UserToken.

IWAB0380E Errors were encountered while validating XML schemas.
XSD: Type reference 'http://datas.demo.xfire.codehaus.org#Customer' is
unresolved
XSD: Type reference 'http://datas.demo.xfire.codehaus.org#UserToken'
is unresolved
IWAB0387I http://localhost:19991/xylos-soa/services/CustomerService?wsdl
is refreshed.

How could I avoid such errors ?

Thanks for your help

---------------------------------------------------------------------
To unsubscribe from this list please visit:

   http://xircles.codehaus.org/manage_email

Reply via email to