Hello Anne ,

here ! The code of my WSDL file .

Thanks for your help.

Anne Thomas Manes a �crit:

Are you sure that you have the WSDL URL, the namespace, and the service name correct?
Can you send us your WSDL file?


At 07:39 AM 4/6/2004, you wrote:

Hi friends !!!

I am writing an application using jax-rpc:
I am trying to call a webservice.
The code of the client is:
___________________________________
URL urlWsdl = new URL("http://localhost:8080/axis/services/urn:xmltoday-delayed-services?wsdl";);



String nameSpaceUri = "urn:xmltoday-delayed-services";


String serviceName = "TravelAgency";

String portName = "TravelAgency";

ServiceFactory serviceFactory = ServiceFactory.newInstance();

javax.xml.rpc.Service service
= serviceFactory.createService(urlWsdl, new QName(nameSpaceUri, serviceName) );


TravelAgencyInterface myProxy = (TravelAgencyInterface) service.getPort(new
QName(nameSpaceUri, portName), TravelAgencyInterface.class );
_______________________


And , when the program  execute the instruction
serviceFactory.createService(... )      the error is :

samples.fede.GetQuote:addPerson: Exception >>javax.xml.rpc.ServiceException<<
samples.fede.GetQuote:addPerson: Message >>Error processing WSDL document:
javax.xml.rpc.ServiceException: Error processing WSDL document:
javax.xml.rpc.ServiceException: Cannot find service:
{urn:xmltoday-delayed-services}TravelAgency<<


What can I do ?
Any help is well received  !!
In advance thanks,

Ricardo DE LA ROSA
IMAG - Grenoble - France

PD:  The WSDL is in the following page.
____________________________________
One part of the WSDL is:

<?xml version="1.0" ?>

<definitions name="urn:TravelAgency"
            targetNamespace="urn:xmltoday-delayed-services"
            xmlns:tns="urn:xmltoday-delayed-services"
            xmlns:xsd="http://www.w3.org/2001/XMLSchema";
            xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
            xmlns="http://schemas.xmlsoap.org/wsdl/";>

<!-- message declns http://xml.apache.org/xml-soap -->

<wsdl:types>
<schema targetNamespace="http://xml.apache.org/xml-soap"; xmlns="http://www.w3.org/2001/XMLSchema";>
<import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
<complexType name="Person">
<sequence>
<element name="Name" nillable="true" type="xsd:string"/>
<element name="Age" type="xsd:int"/>
</sequence>
</complexType>


</schema>
.....
<wsdl:message name="addPersonResponse">
<wsdl:part name="addPersonReturn" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="addPersonRequest">
<wsdl:part name="in0" type="typens:Person"/>
</wsdl:message>
......
<portType name="TravelAgency">
.....
<wsdl:operation name="addPerson" parameterOrder="in0">
<wsdl:input name="addPersonRequest" message="impl:addPersonRequest"/>
<wsdl:output name="addPersonResponse" message="impl:addPersonResponse"/>
</wsdl:operation>
</portType>
......
<binding name="TravelAgencyBinding" type="tns:TravelAgency">
<soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>


........
     <operation name="addPerson">

<wsdlsoap:operation soapAction=""/>

<wsdl:input name="addPersonRequest">

<wsdlsoap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; namespace="urn:xmltoday-delayed-services"/>

</wsdl:input>

<wsdl:output name="addPersonResponse">

<wsdlsoap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; namespace="urn:xmltoday-delayed-services"/>

</wsdl:output>

</operation>

 </binding>
....
</definitions>




~~~~~~~~~~~~~~~~~~
Anne Thomas Manes
VP & Research Director
Burton Group


<?xml version="1.0" ?>

<definitions name="TravelAgency" 
             targetNamespace="urn:xmltoday-delayed-services"
             xmlns:tns="urn:xmltoday-delayed-services"
             xmlns:xsd="http://www.w3.org/2001/XMLSchema";
             xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
             xmlns="http://schemas.xmlsoap.org/wsdl/";>

  <!-- message declns  http://xml.apache.org/xml-soap    -->

 <wsdl:types>
  <schema targetNamespace="urn:xmltoday-delayed-services" 
xmlns="http://www.w3.org/2001/XMLSchema";>
   <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>

   <complexType name="Person">
    <sequence>
     <element name="Name" nillable="true" type="xsd:string"/>
     <element name="Age" type="xsd:int"/>
    </sequence>
   </complexType>

  </schema>

 </wsdl:types>

  <message name="testRequest"/>
  <message name="testResponse">
    <part name="testResult" type="xsd:string"/>
  </message>

  <message name="TravelAgencyRequest">
    <part name="symbol" type="xsd:string"/>
  </message>

  <message name="TravelAgencyResponse">
    <part name="result" type="xsd:string"/>
  </message>

   <message name="getSeatDetailsResponse">
      <part name="getSeatDetailsReturn" type="xsd:string"/>
   <message>

   <message name="getSeatDetailsRequest">
      <wsdl:part name="in0" type="xsd:string" />
      <wsdl:part name="in1" type="xsd:string" />
   </message>


   <wsdl:message name="addPersonResponse">

      <wsdl:part name="addPersonReturn" type="xsd:string"/>

   </wsdl:message>

   <wsdl:message name="addPersonRequest">

      <wsdl:part name="in0" type="typens:Person"/>

   </wsdl:message>


  <!-- port type declns -->

  <portType name="TravelAgency">

    <operation name="getHello" >
      <input  message="tns:TravelAgencyRequest"/>
      <output message="tns:TravelAgencyResponse"/>
    </operation>

    <operation name="test" >
      <input message="tns:testRequest"/>
      <output message="tns:testResponse"/>
    </operation>

    <operation name="getSeatDetails" parameterOrder="in0 in1">
        <input message="impl:getSeatDetailsRequest" name="getSeatDetailsRequest"/>
        <output message="impl:getSeatDetailsResponse" name="getSeatDetailsResponse"/>
    </operation>

      <wsdl:operation name="addPerson" parameterOrder="in0">
         <wsdl:input name="addPersonRequest" message="impl:addPersonRequest"/>
         <wsdl:output name="addPersonResponse" message="impl:addPersonResponse"/>
      </wsdl:operation>

  </portType>

  <!-- binding declns -->
  <binding name="TravelAgencyBinding" type="tns:TravelAgency">
    <soap:binding style="rpc" 
                  transport="http://schemas.xmlsoap.org/soap/http"/>

    <operation name="getHello">
      <soap:operation soapAction="getHello"/>
      <input>
        <soap:body use="encoded" 
                   namespace="urn:xmltoday-delayed-services" 
                   encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
      </input>
      <output>
        <soap:body use="encoded" 
                   namespace="urn:xmltoday-delayed-services"
                   encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
      </output>
    </operation>

      <operation name="getSeatDetails">
         <wsdlsoap:operation soapAction=""/>
         <wsdl:input name="getSeatDetailsRequest">
            <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; 
                           namespace="urn:xmltoday-delayed-services" use="encoded"/>
         </wsdl:input>
         <wsdl:output name="getSeatDetailsResponse">
            <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; 
                           namespace="urn:xmltoday-delayed-services" use="encoded"/>
         </wsdl:output>
      </operation>

    <operation name="test">
      <soap:operation soapAction="test"/>
      <input>
        <soap:body use="encoded" 
                   namespace="urn:xmltoday-delayed-services" 
                   encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
      </input>
      <output>
        <soap:body use="encoded" 
                   namespace="urn:xmltoday-delayed-services"
                   encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
      </output>
    </operation>

      <operation name="addPerson">

         <wsdlsoap:operation soapAction=""/>

         <wsdl:input name="addPersonRequest">

            <wsdlsoap:body use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; 
namespace="urn:xmltoday-delayed-services"/>

         </wsdl:input>

         <wsdl:output name="addPersonResponse">

            <wsdlsoap:body use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"; 
namespace="urn:xmltoday-delayed-services"/>

         </wsdl:output>

      </operation>

  </binding>

  <!-- service decln -->
  <service name="TravelAgency">
    <port name="TravelAgency" binding="tns:TravelAgencyBinding">
      <soap:address location="http://localhost:8080/axis/servlet/AxisServlet"/>
    </port>
    <port name="TravelAgencyJava" binding="tns:TravelAgencyBinding">
      <soap:address location="java:samples.fede.TravelAgency"/>
    </port>
  </service>

</definitions>

Reply via email to