You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Paul Fremantle <pz...@gmail.com> on 2008/02/26 18:18:40 UTC

Java2WSDL's choice of namespaces

I recently used the Eclipse WebTools WSDL validator. It doesn't like
the way that Axis2 creates Schemas. If you look at the AddressBook
WSDL that gives you a good example.

    <wsdl:types>
        <xs:schema xmlns:ns="http://service.addressbook.sample"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://service.addressbook.sample">
            <xs:element name="findEntry">
            .... wrapper elements here
        </xs:schema>
        <xs:schema xmlns:ax21="http://entry.addressbook.sample/xsd"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://entry.addressbook.sample/xsd">
            <xs:complexType name="Entry">
            .... data type elements here

The problem is that the wrapper elements refer to the data-type
complextypes, which are defined in two separate schema chunks. So the
Eclipse WSDL validator sees these as separate and cannot resolve the
cross references.

Now the reason - I'm guessing - that Axis2 generates these in separate
schema chunks, is because it wants to give them separate target
namespaces.

So here are my questions:

1) I think this is new to 1.3 ... I certainly remember validating
WSDLs generated with older versions of Axis2 without problem.

2) Is it necessary to have the two target namespaces (sample vs sample/xsd)?

3) Can we fix this easily? Is there anyway of doing an import from one
chunk to the other.

Paul


-- 
Paul Fremantle
Co-Founder and VP of Technical Sales, WSO2
OASIS WS-RX TC Co-chair

blog: http://pzf.fremantle.org
paul@wso2.com

"Oxygenating the Web Service Platform", www.wso2.com

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: Java2WSDL's choice of namespaces

Posted by Deepal Jayasinghe <de...@opensource.lk>.
> I recently used the Eclipse WebTools WSDL validator. It doesn't like
> the way that Axis2 creates Schemas. If you look at the AddressBook
> WSDL that gives you a good example.
>
>     <wsdl:types>
>         <xs:schema xmlns:ns="http://service.addressbook.sample"
> attributeFormDefault="qualified" elementFormDefault="qualified"
> targetNamespace="http://service.addressbook.sample">
>             <xs:element name="findEntry">
>             .... wrapper elements here
>         </xs:schema>
>         <xs:schema xmlns:ax21="http://entry.addressbook.sample/xsd"
> attributeFormDefault="qualified" elementFormDefault="qualified"
> targetNamespace="http://entry.addressbook.sample/xsd">
>             <xs:complexType name="Entry">
>             .... data type elements here
>
> The problem is that the wrapper elements refer to the data-type
> complextypes, which are defined in two separate schema chunks. So the
> Eclipse WSDL validator sees these as separate and cannot resolve the
> cross references.
>
> Now the reason - I'm guessing - that Axis2 generates these in separate
> schema chunks, is because it wants to give them separate target
> namespaces.
>
> So here are my questions:
>
> 1) I think this is new to 1.3 ... I certainly remember validating
> WSDLs generated with older versions of Axis2 without problem.
>
> 2) Is it necessary to have the two target namespaces (sample vs sample/xsd)?
>
> 3) Can we fix this easily? Is there anyway of doing an import from one
> chunk to the other.
>   
Yes we can (and should) fix this for next version

Thanks
Deepal



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org