axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bhanu Pabreja" <pabr...@infigroup.com>
Subject RE: Java2WSDL generating empty target NS for doc-style
Date Fri, 16 May 2003 19:20:21 GMT
what I told you this is a manual way to do things...

I think the axis committers have actually taken care of this bug and if you
go to the interin drop and download the latest built of axis you can run
your script using that and your WSDL will be perfect. Then basically you can
roll back to the RC2 if you like ...

This is how I did and it worked for me ...

dumdum420

-----Original Message-----
From: Steve Pannier [mailto:Steve_Pannier.CST@jacada.com]
Sent: Friday, May 16, 2003 3:15 PM
To: axis-user@ws.apache.org
Subject: RE: Java2WSDL generating empty target NS for doc-style



Thanks, but, how do I do this using Java2WSDL?  My goal is to
*not* have to manually modify the WSDL after running Java2WSDL.
(We are programmatically creating the wsdl to describe our services.)


Steve Pannier



> get rid of the targetNamespace attriute for the moment ...
>
> and prefix all your <wsdl:message> type attribute with the impl:xxxxxx .
The
> impl is a valid namespace delecration in the begining of your WSDL ...
>
> Hope this helps ...
>
>
> dumdum420.
>
> -----Original Message-----
> From: Steve Pannier [mailto:Steve_Pannier.CST@jacada.com]
> Sent: Friday, May 16, 2003 2:55 PM
> To: axis-user@ws.apache.org
> Subject: Java2WSDL generating empty target NS for doc-style
>
>
> I've successfully deployed RPC style services and created the
> WSDL for them using Java2WSDL.  I then used the WSDL to create
> client stubs (by using WSDL2Java, and other tools like Websphere
> App. Developer, JDeveloper, etc) and have successfully invoked
> my service methods.
>
> Now, I'm starting to make use of document/message style services.
> I would like to use the same approach (that is, Java2WSDL, then
> WSDL2Java to create client stubs).  I tried this, but when I run
> WSDL2Java, I get the error:
>
> "Element {http://schemas.xmlsoap.org/wsdl/}getCustomerReturn
> is referenced but not defined".
>
> But "getCustomerReturn" is defined, and from looking at the
> Axis-User archives, the problem seems to be the blank target
> namespace.
>
> Does anyone know of a way to get around this?  An argument to
> Java2WSDL maybe?  Or shouldn't I even expect to use this
> approach with Doc style services?  Can anyone shed some light?
>
>
> My doc-style service:
>
>
> package com.test.message;
>
> import org.w3c.dom.Element;
>
> public class MyDocService {
>
>      public MyDocService() { }
>
>     public Element[] echoElements(Element [] elems) throws Exception {
>         // Not yet implemented
>         return null;
>     }
>     public Element getCustomer(Element [] elems) throws Exception {
>         // Not yet implemented
>         return null;
>     }
> }
>
>
> The relevant sections of the generated WSDL:
>
>
> <wsdl:types>
>   <schema targetNamespace="http://message.test.com" xmlns
> ="http://www.w3.org/2001/XMLSchema">
>    <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
>    <complexType name="ArrayOf_apachesoap_Element">
>     <complexContent>
>      <restriction base="soapenc:Array">
>       <attribute ref="soapenc:arrayType" wsdl:arrayType
="apachesoap:Element
> []"/>
>      </restriction>
>     </complexContent>
>    </complexType>
>   </schema>
>   <schema targetNamespace="" xmlns="http://www.w3.org/2001/XMLSchema">
>    <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
>    <element name="elems" type="impl:ArrayOf_apachesoap_Element"/>
>    <element name="echoElementsReturn" type
> ="impl:ArrayOf_apachesoap_Element"/>
>    <element name="elems" type="impl:ArrayOf_apachesoap_Element"/>
>    <element name="getCustomerReturn" type="apachesoap:Element"/>
>   </schema>
>  </wsdl:types>
>
>    <wsdl:message name="getCustomerRequest">
>       <wsdl:part element="elems" name="elems"/>
>    </wsdl:message>
>    <wsdl:message name="echoElementsResponse">
>       <wsdl:part element="echoElementsReturn" name="echoElementsReturn"/>
>    </wsdl:message>
>    <wsdl:message name="echoElementsRequest">
>       <wsdl:part element="elems" name="elems"/>
>    </wsdl:message>
>    <wsdl:message name="getCustomerResponse">
>       <wsdl:part element="getCustomerReturn" name="getCustomerReturn"/>
>    </wsdl:message>
>
>
>
> Regards.
>
> Steve Pannier
>
>
>
>
>






Mime
View raw message