axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yu-Hui Jin" <yuhui....@gmail.com>
Subject Re: WS works, but cannot view WSDL
Date Wed, 22 Feb 2006 05:53:21 GMT
How do we do it in Axis2?

regards,

-Hui



On 2/21/06, Shaoguang Cong <scong1111@yahoo.com> wrote:
>
> Assume vmr is a directory under your webapp root.  Try specify the
> <wsdlFile> tag as
> <wsdlFile>vmr/VMRService.wsdl <http://localhost:8084/vmr/VMRService.wsdl>
> </wsdlFile
> By this way you can view the WSDL in the browser or via the Axis servlet
> (the ?wsdl url).
>
> Shaoguang
>
> *Anne Thomas Manes <atmanes@gmail.com>* wrote:
>
> Right -- that's because the WSDL is at the URL you specified:
> http://localhost:8084/vmr/VMRService.wsdl, and it is no longer generated
> by Axis, so there isn't a WSDL file at
> http://myip:myport/services/VMRService?wsdl<http://myip/services/VMRService?wsdl>.
>
>
> Anne
>
> On 2/17/06, Greg Michalopoulos <GMichalopoulos@d2hawkeye.com> wrote:
> >
> > I understand all that you replied, except I think I must be doing
> > something wrong.  I made all the changes and made <wsdlFile>
> > http://localhost:8084/vmr/VMRService.wsdl</wsdlFile>.  Now the output of
> > ?wsdl is
> >
> > Fault - Unable to find WSDL file or resource
> > http://localhost:8084/vmr/VMRService.wsdl
> >
> > If I cut and paste that URL into a webbrowser, it shows the wsdl no
> > problem.  Any ideas?
> >
> >  ------------------------------
> > *From:* Anne Tho mas Manes [mailto:atmanes@gmail.com]
> > *Sent:* Friday, February 17, 2006 10:57 AM
> > *To:* axis-user@ws.apache.org
> > *Subject:* Re: WS works, but cannot view WSDL
> >
> >  Since you have defined your own WSDL, I suggest you tell Axis to use
> > your WSDL rather than generating a new one. You do so by specifying:
> >
> > <wsdlFile>[wsdl-url]</wsdlFile>
> >
> > in the WSDD. (make sure that you change the soap:location attribute to
> > point to the correct URL)
> >
> > Doing so allows you to remove the following parameters from the WSDD:
> >
> > <parameter name="wsdlTargetNamespace"
> >    & nbsp; value="http://d2hawkeye.com/api/vmr/"/>
> > <parameter name="wsdlServiceElement" value="VMRService"/>
> > <parameter name="schemaUnqualified"
> >      value="http://d2hawkeye.com/api/vmr/"/>
> > <parameter name="wsdlServicePort" value="VMRService"/>
> > <parameter name="wsdlPortType" value="VMR"/>
> >
> > One more note: you should remove the namespace attributes from the
> > <wsdlsoap:body> definitions in your binding. The namespace attribute should
> > be use only with RPC style services.
> >
> > Anne
> >
> > On 2/17/06, Greg Michalopoulos <GMichalopoulos@d2hawkeye.com> wrote:
> > >
> > > Using Axis 1.3. I created the WSDL below by hand (via xsl).  I created
> > > the skeleton and stub using WSDL2Java no problem, but the deploy.wsdd
> > > (below as well) has lines like this - qname="ns:>Claim" - when I
> > > expected it to be - qname="ns:Claim".  I am able to deploy and use the
> > > web service without issue.  The problem is that when I goto
> > > http://myip:myport/services/VMRService?wsdl I get the following error:
> > >
> > > AXIS error
> > >
> > > Sorry, something seems to have gone wrong... here are the details:
> > >
> > > Fault - makeTypeElement() was told to create a type
> > > "{ http://d2hawkeye.com/api/vmr/} <http://d2hawkeye.com/api/vmr/%7D>>Claim",
> > > with no containing element
> > >
> > > AxisFault
> > > faultCode:
> > > {http://schemas.xmlsoap.org/soap/envelope/}Server.generalException
> > > <http://schemas.xmlsoap.org/soap/envelope/%7DServer.generalException>
> > > faultSubcode:
> > > faultString: makeTypeElement() was told to create a type
> > > "{http://d2hawkeye.com/api/vmr/} <http://d2hawkeye.com/api/vmr/%7D>>Claim",
> > > with no containing element
> > > faultActor:
> > > faultNode:
> > > faultDetail:
> > >         {http://xml.apache.org/axis/}hostname<http://xml.apache.org/axis/%7Dhostname>
> > > :
> > >
> > > So while it appears to be working fine, I know something is wrong but
> > > not sure where.  I'm guessing my namespaces but am not sure how to
> > > figure this out.  Any suggestions welcome.
> > >
> > > Thanks,
> > > Greg
> > >
> > > ***WSDL***
> > >
> > > <?xml version="1.0" encoding="UTF-8"?>
> > > <!--
> > >   Automatically generated by parsing Clover-ETL output with XSL script
> > >
> > > -->
> > > <wsdl:definitions targetNamespace="http://d2hawkeye.com/api/vmr/"
> > > xmlns=" http://schemas.xmlsoap.org/wsdl/ "
> > > xmlns:apachesoap="http://xml.apache.org/xml-soap"
> > > xmlns:impl=" http://d2hawkeye.com/api/vmr/"
> > > xmlns:intf="http://d2hawkeye.com/api/vmr/"
> > > xmlns:soapenc=" http://schemas.xmlsoap.org/soap/encoding/"
> > > xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
> > > xmlns:wsdlsoap=" http://schemas.xmlsoap.org/wsdl/soap/"
> > > xmlns:xsd="http://www.w3.org/2001/XMLSchema">
> > > <wsdl:types>
> > >   <schema targetNamespace="http://d2hawkeye.com/api/vmr/ "
> > > xmlns="http://www.w3.org/2001/XMLSchema">
> > >    <element name="Claim">
> > >      <complexType>
> > >       <sequence>
> > >        <element maxOccurs="1" minOccurs="0" name="SN" type="xsd:float"
> > >
> > > />
> > >        ...
> > >          ...
> > >        <element maxOccurs="1" minOccurs="0" name="RECEIVEDMONTH"
> > > type="xsd:date" />
> > >       </sequence>
> > >      </complexType>
> > >     </element>
> > >     <element name="Claims">
> > >      <complexType>
> > >       <sequence>
> > >        <element maxOccurs="unbounded" minOccurs="0" ref="impl:Claim"/>
> > >
> > >       </sequence>
> > >      </complexType>
> > >     </element>
> > >     <element name="Member">
> > >      <complexType>
> > >       <sequence>
> > >        <element maxOccurs="1" minOccurs="1" name="memberID"
> > > type="xsd:string"/>
> > >        <element maxOccurs="1" minOccurs="0" ref="impl:Claims"/>
> > >       </sequence>
> > >      </complexType>
> > >     </element>
> > >   </schema>
> > > </wsdl:types>
> > > <wsdl:mes sage name="getVMRRequest">
> > >   <wsdl:part name="MemberReq" element="impl:Member"/>
> > > </wsdl:message>
> > > <wsdl:message name="getVMRResponse">
> > >   <wsdl:part name="MemberRes" element="impl:Member"/>
> > > </wsdl:message>
> > > <wsdl:portType name="VMR">
> > >   <wsdl:operation name="getVMR">
> > >    <wsdl:input message="impl:getVMRRequest" name="getVMRRequest"/>
> > >    <wsdl:output message="impl:getVMRResponse" name="getVMRResponse"/>
> > >   </wsdl:operation>
> > > </wsdl:portType>
> > > <wsdl:binding name="VMRServiceSoapBinding" type="impl:VMR">
> > >   <wsdlsoap:binding style="document"
> > > transport="http://schemas.xmlsoap.org/soap/http "/>
> > >   <wsdl:operation name="getVMR">
> > >    <wsdlsoap:operation soapAction=""/>
> > >    <wsdl:input name="getVMRRequest">
> > >     <wsdlsoap:body namespace="http://d2hawkeye.com/api/vmr/ "
> > > use="literal"/>
> > >    </wsdl:input>
> > >    <wsdl:output name="getVMRResponse">
> > >     <wsdlsoap:body namespace="http://d2hawkeye.com/api/vmr/ "
> > > use="literal"/>
> > >    </wsdl:output>
> > >   </wsdl:operation>
> > > </wsdl:binding>
> > > <wsdl:service name="VMRService">
> > >   <wsdl:port binding="impl:VMRServiceSoapBinding" name="VMRService">
> > >    <wsdlsoap:address
> > > location="http://localhost:8084/services/VMRService"/>
> > >   </wsdl:port>
> > > </wsdl:service>
> > > </wsdl:definitions>
> > >
> > > ***WSDL***
> > >
> > > ***WSDD***
> > >
> > > <!-- Use this file to deploy some handlers/chains and
> > > services      -->
> > > <!-- Two ways to do this:
> > > -->
> > > <!--   java org.apache.axis.client.AdminClient deploy.wsdd
> > >           -->
> > > <!--      after the axis server is
> > > running                          -->
> > > <!-- or
> > > -->
> > > <!--   java org.apache.axis.utils.Admin client|server deploy.wsdd
> > > -->
> > > <!--      from the same directory that the Axis engine runs
> > > -->
> > >
> > > <deployment
> > >     xmlns=" http://xml.apache.org/axis/wsdd/"
> > >     xmlns:java="http://xml.apache.org/axis/wsdd/providers/java ">
> > >
> > >   <!-- Services from VMRService WSDL service -->
> > >
> > >   <service name="VMRService" provider="java:RPC" style="document"
> > > use="literal">
> > >       <parameter name="wsdlTargetNamespace"
> > > value=" http://d2hawkeye.com/api/vmr/"/>
> > >       <parameter name="wsdlServiceElement" value="VMRService"/>
> > >       <parameter name="schemaUnqualified"
> > > value=" http://d2hawkeye.com/api/vmr/"/>
> > >       <parameter name="wsdlServicePort" value="VMRService"/>
> > >       <parameter name="className"
> > > value="com.d2hawkeye.api.vmr.VMRServiceSoapBindingSkeleton "/>
> > >       <parameter name="wsdlPortType" value="VMR"/>
> > >       <parameter name="typeMappingVersion" value="1.2"/>
> > >       <parameter name="allowedMethods" value="*"/>
> > >       <parameter name="scope" value="Session"/>
> > >
> > >       <typeMapping
> > >         xmlns:ns="http://d2hawkeye.com/api/vmr/ "
> > >         qname="ns:>Claim"
> > >         type="java:com.d2hawkeye.api.vmr.Claim"
> > >         serializer="org.apache.axis.encoding.ser.BeanSerializerFactory
> > > "
> > >
> > > deserializer="org.apache.axis.encoding.ser.BeanDeserializerFactory "
> > >         encodingStyle=""
> > >       />
> > >       <typeMapping
> > >         xmlns:ns=" http://d2hawkeye.com/api/vmr/"
> > >         qname="ns:>Member"
> > >         type="java:com.d2hawkeye.api.vmr.Member"
> > >         serializer="org.apache.axis.encoding.ser.BeanSerializerFactory
> > > "
> > >
> > > deserializer="org.apache.axis.encoding.ser.BeanDeserializerFactory "
> > >         encodingStyle=""
> > >       />
> > >       <arrayMapping
> > >         xmlns:ns=" http://d2hawkeye.com/api/vmr/"
> > >         qname="ns:>Claims"
> > >         type="java:com.d2hawkeye.api.vmr.Claim[]"
> > >         innerType="cmp-ns:Claim"
> > > xmlns:cmp-ns=" http://d2hawkeye.com/api/vmr/"
> > >         encodingStyle=""
> > >       />
> > >   </service>
> > > </deployment>
> > >
> > > ***WSDD***
> > >
> >
> >
>
> ------------------------------
> Yahoo! Mail
> Use Photomail<http://us.rd.yahoo.com/mail_us/taglines/pmall2/*http://photomail.mail.yahoo.com>to
share photos without annoying attachments.
>
>

Mime
View raw message