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 Ajith Ranabahu <aj...@gmail.com> on 2005/08/24 14:09:36 UTC

[Axis2] Clarification needed on the Types section

Hi all,
the following piece of WSDL is from the WSRF WSDL at 
http://docs.oasis-open.org/wsrf/rpw-1

<wsdl:types>
     <xsd:schema>
       <xsd:import
         namespace="http://docs.oasis-open.org/wsrf/rp-1" 
         schemaLocation="http://docs.oasis-open.org/wsrf/rp-1" />
     </xsd:schema>
   </wsdl:types>

Axis2 code generator is configured to throw an exception if it encounters a 
schema element that does not declare a target namespace. Is that correct in 
this case ?
-- 
Ajith Ranabahu

Re: [Axis2] Clarification needed on the Types section

Posted by Ajith Ranabahu <aj...@gmail.com>.
during XMLBeans schema compilation ?


On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
> 
> Ajith,
> 
> In Axis 1.X and elsewhere, people default to wsdl's targetNamespace.
> can't we do that instead?
> 
> -- dims
> 
> On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> > Hi Dims,
> > I actually discussed this with Sanjiva after going through the specs. 
> He's
> > in the view that the schema defined in the WSDL needs to have the
> > targetNamespace attribute even though it is not mandatory according to 
> the
> > schema spec. The reason is that if the elements are unqualified then the
> > messages section might have a problem refering to the elements.Thesefacts
> > do not seem to be documented anywhere :(
> > However I feel Jaya's solution seems to be valid since it serves the 
> WSDL's
> > purpose!
> >
> > Thoughts ?
> >
> >
> >
> > On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
> > > check the xsd schema's schema. if it is mandatory then throw exception
> > > if it is absent otherwise don't.
> > >
> > > -- dims
> > >
> > > On 8/24/05, jayachandra <jayachandra@gmail.com > wrote:
> > > > Ajith!
> > > > If the content inside the <xsd:schema> element is(are) just an 
> import
> > > > statement(s) then, I guess, there need not be a targetNamespace.
> > > > However if any information other than import elements appear (viz.
> > > > element declarations, include statements etc.) then we should throw
> > > > that exception. Just my thought, though
> > > >
> > > > Thank you
> > > > Jayachandra
> > > >
> > > > On 8/24/05, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> > > > > Hi all,
> > > > > the following piece of WSDL is from the WSRF WSDL at
> > > > > http://docs.oasis-open.org/wsrf/rpw-1
> > > > >
> > > > > <wsdl:types>
> > > > > <xsd:schema>
> > > > > <xsd:import
> > > > > namespace="http://docs.oasis-open.org/wsrf/rp-1 "
> > > > > schemaLocation="
> > > > http://docs.oasis-open.org/wsrf/rp-1" />
> > > > > </xsd:schema>
> > > > > </wsdl:types>
> > > > > Axis2 code generator is configured to throw an exception if it
> > encounters a
> > > > > schema element that does not declare a target namespace. Is that
> > correct in
> > > > > this case ?
> > > > > --
> > > > > Ajith Ranabahu
> > > >
> > > >
> > > > --
> > > > -- Jaya
> > > >
> > >
> > >
> > > --
> > > Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service 
> Platform
> > >
> >
> >
> >
> > --
> > Ajith Ranabahu
> 
> 
> --
> Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform
> 



-- 
Ajith Ranabahu

Re: [Axis2] Clarification needed on the Types section

Posted by Sanjiva Weerawarana <sa...@opensource.lk>.
On Wed, 2005-08-24 at 16:48 -0400, Davanum Srinivas wrote:
> Bottom line? don't throw an error with the wsrf wsdl. right?

Yes ;-).

Sanjiva.



Re: [Axis2] Clarification needed on the Types section

Posted by Davanum Srinivas <da...@gmail.com>.
Bottom line? don't throw an error with the wsrf wsdl. right?

-- dims

On 8/24/05, Sanjiva Weerawarana <sa...@opensource.lk> wrote:
> On Wed, 2005-08-24 at 09:19 -0400, Glen Daniels wrote:
> > Dims, you can only do that if WSDL says that's what you do (otherwise
> > it's not interoperable, or correct according to schema).
> >
> > I don't see the problem Sanjiva is worried about, though.  If the
> > elements are unqualified, then the references are simply unqualified as
> > well... <input element="foo"/> instead of <input element="ns:foo"/> -
> > what's the big deal?
> 
> The rules for resolving qualified *values* that WSDL 1.1 assumed came
> from XSLT, not from WSDL. (See http://www.w3.org/TR/xslt#qname.) So
> while you're correct about how one could interpret
> element="foo" (because XSDL explicitly states that default NS doesn't
> apply), it was not the intent of WSDL 1.1 that unqualified names would
> be used as values of @element and @type. Furthermore, WSDL 1.1, does not
> specify or imply the behavior you propose.
> 
> For those of you who care about the WS-I Basic Profile, it clarifies
> this issue too:
> 
> http://www.ws-i.org/Profiles/BasicProfile-1.0-2004-04-16.html#refinement16552904
> 
> However, the solution they advocate (which is what the WS-RF schema
> uses) is actually incorrect w.r.t. XSD IMO .. the EIIs and AIIs defined
> in the schema which is imported inside another schema are not visible
> outside of the enclosing schema. So in other words, WSDL would not be
> able to see them. WS-I BP gets around that by defining its own rules ..
> but technically that's not correct.
> 
> Anyway, I take back my previous comment: this *specific style of XSDs*
> (per the WS-I BP clarification) should be supported as a special case.
> The style being of course:
>         <xsd:schema>
>                 <xsd:import namespace=".." location=".."/>
>         </xsd:schema>
> This is analogous to what we allow in WSDL 2.0 by allowing xsd:import
> directly as a child of wsdl:types.
> 
> We clarified this whole issue in WSDL 2.0 after lots of thought. See:
>         http://www.w3.org/TR/2005/WD-wsdl20-20050803/#xsd-types
> 
> There we say (in 3.1.1.1):
> 
> "The namespace attribute information item defines the namespace of the
> element declarations and type definitions imported from the referenced
> schema. The referenced schema MUST contain a targetNamespace attribute
> information item on its xs:schema element information item and the
> values of these two attribute information items MUST be identical. It is
> an error to import a schema that does not have a targetNamespace
> attribute information item on its xs:schema element information item.
> Such schemas must first be included (using xs:include ) in a schema that
> contains a targetNamespace attribute information item on its xs:schema
> element information item, which can then be either imported or inlined
> in the WSDL 2.0 document."
> 
> ===
> 
> In WSDL 1.1, the trick we used was to say you can use WSDL 1.1's
> <import> element to import XSDs. (See Section 2.1.2 of
> http://www.w3.org/TR/wsdl.) So the right way to do the above would've
> been to write:
>         <wsdl:definitions ...>
> 
>                 <wsdl:import namespace=".." location=".."/>
>                 ..
>         </wsdl:definitions>
> 
> The WSDL processor was responsible for sniffing the stuff at the
> location URI and figuring out whether to import it as XSD or as WSDL (or
> some other type system .. in the WSIF context people have used it to
> import weirdities like COBOL copy books ;-)).
> 
> However, WS-I BP folks, in their infinite wisdom, felt this was no good
> and declared this illegal:
> 
> http://www.ws-i.org/Profiles/BasicProfile-1.0-2004-04-16.html#refinement16498504
> 
> (It baffles me how WS-I BP folks felt they could re-write the WSDL 1.1's
> recommended authoring style (http://www.w3.org/TR/wsdl#_style) but
> that's what they did. Oh well.)
> 
> Sanjiva.
> 
> 
> 


-- 
Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform

Re: [Axis2] Clarification needed on the Types section

Posted by Sanjiva Weerawarana <sa...@opensource.lk>.
On Wed, 2005-08-24 at 09:19 -0400, Glen Daniels wrote:
> Dims, you can only do that if WSDL says that's what you do (otherwise 
> it's not interoperable, or correct according to schema).
> 
> I don't see the problem Sanjiva is worried about, though.  If the 
> elements are unqualified, then the references are simply unqualified as 
> well... <input element="foo"/> instead of <input element="ns:foo"/> - 
> what's the big deal?

The rules for resolving qualified *values* that WSDL 1.1 assumed came
from XSLT, not from WSDL. (See http://www.w3.org/TR/xslt#qname.) So
while you're correct about how one could interpret
element="foo" (because XSDL explicitly states that default NS doesn't
apply), it was not the intent of WSDL 1.1 that unqualified names would
be used as values of @element and @type. Furthermore, WSDL 1.1, does not
specify or imply the behavior you propose. 

For those of you who care about the WS-I Basic Profile, it clarifies
this issue too:

http://www.ws-i.org/Profiles/BasicProfile-1.0-2004-04-16.html#refinement16552904

However, the solution they advocate (which is what the WS-RF schema
uses) is actually incorrect w.r.t. XSD IMO .. the EIIs and AIIs defined
in the schema which is imported inside another schema are not visible
outside of the enclosing schema. So in other words, WSDL would not be
able to see them. WS-I BP gets around that by defining its own rules ..
but technically that's not correct.

Anyway, I take back my previous comment: this *specific style of XSDs*
(per the WS-I BP clarification) should be supported as a special case.
The style being of course:
	<xsd:schema>
		<xsd:import namespace=".." location=".."/>
	</xsd:schema>
This is analogous to what we allow in WSDL 2.0 by allowing xsd:import
directly as a child of wsdl:types. 

We clarified this whole issue in WSDL 2.0 after lots of thought. See:
	http://www.w3.org/TR/2005/WD-wsdl20-20050803/#xsd-types

There we say (in 3.1.1.1):

"The namespace attribute information item defines the namespace of the
element declarations and type definitions imported from the referenced
schema. The referenced schema MUST contain a targetNamespace attribute
information item on its xs:schema element information item and the
values of these two attribute information items MUST be identical. It is
an error to import a schema that does not have a targetNamespace
attribute information item on its xs:schema element information item.
Such schemas must first be included (using xs:include ) in a schema that
contains a targetNamespace attribute information item on its xs:schema
element information item, which can then be either imported or inlined
in the WSDL 2.0 document."

===

In WSDL 1.1, the trick we used was to say you can use WSDL 1.1's
<import> element to import XSDs. (See Section 2.1.2 of
http://www.w3.org/TR/wsdl.) So the right way to do the above would've
been to write:
	<wsdl:definitions ...>

		<wsdl:import namespace=".." location=".."/>
		..
	</wsdl:definitions>

The WSDL processor was responsible for sniffing the stuff at the
location URI and figuring out whether to import it as XSD or as WSDL (or
some other type system .. in the WSIF context people have used it to
import weirdities like COBOL copy books ;-)). 

However, WS-I BP folks, in their infinite wisdom, felt this was no good
and declared this illegal:

http://www.ws-i.org/Profiles/BasicProfile-1.0-2004-04-16.html#refinement16498504

(It baffles me how WS-I BP folks felt they could re-write the WSDL 1.1's
recommended authoring style (http://www.w3.org/TR/wsdl#_style) but
that's what they did. Oh well.)

Sanjiva.



Re: [Axis2] Clarification needed on the Types section

Posted by Davanum Srinivas <da...@gmail.com>.
FWIW, from what i remember i think Axis 1.x does that as well as xmlspy.

On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
> ok. but anyways the bottom line is the wsdl in question (wsrf) is a
> valid wsdl with a valid schema and we should not fail.
> 
> -- dims
> 
> On 8/24/05, Glen Daniels <gl...@thoughtcraft.com> wrote:
> > Dims, you can only do that if WSDL says that's what you do (otherwise
> > it's not interoperable, or correct according to schema).
> >
> > I don't see the problem Sanjiva is worried about, though.  If the
> > elements are unqualified, then the references are simply unqualified as
> > well... <input element="foo"/> instead of <input element="ns:foo"/> -
> > what's the big deal?
> >
> > --G
> >
> > Davanum Srinivas wrote:
> > > Ajith,
> > >
> > > In Axis 1.X and elsewhere, people default to wsdl's targetNamespace.
> > > can't we do that instead?
> > >
> > > -- dims
> > >
> > > On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> > >
> > >>Hi Dims,
> > >> I actually discussed this with Sanjiva after going through the specs. He's
> > >>in the view that the schema defined in the WSDL needs to have the
> > >>targetNamespace attribute even though it is not mandatory according to the
> > >>schema spec. The reason is that if the elements are unqualified then the
> > >>messages section might have a problem refering to the elements.These facts
> > >>do not seem to be documented anywhere :(
> > >> However I feel Jaya's solution seems to be valid since it serves the WSDL's
> > >>purpose!
> > >>
> > >> Thoughts ?
> > >>
> > >>
> > >>
> > >>On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
> > >>
> > >>>check the xsd schema's schema. if it is mandatory then throw exception
> > >>>if it is absent otherwise don't.
> > >>>
> > >>>-- dims
> > >>>
> > >>>On 8/24/05, jayachandra <jayachandra@gmail.com > wrote:
> > >>>
> > >>>>Ajith!
> > >>>>If the content inside the <xsd:schema> element is(are) just an import
> > >>>>statement(s) then, I guess, there need not be a targetNamespace.
> > >>>>However if any information other than import elements appear (viz.
> > >>>>element declarations, include statements etc.) then we should throw
> > >>>>that exception. Just my thought, though
> > >>>>
> > >>>>Thank you
> > >>>>Jayachandra
> > >>>>
> > >>>>On 8/24/05, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> > >>>>
> > >>>>>Hi all,
> > >>>>>the following piece of WSDL is from the WSRF WSDL at
> > >>>>>http://docs.oasis-open.org/wsrf/rpw-1
> > >>>>>
> > >>>>><wsdl:types>
> > >>>>> <xsd:schema>
> > >>>>> <xsd:import
> > >>>>> namespace="http://docs.oasis-open.org/wsrf/rp-1 "
> > >>>>> schemaLocation="
> > >>>>
> > >>>>http://docs.oasis-open.org/wsrf/rp-1" />
> > >>>>
> > >>>>> </xsd:schema>
> > >>>>> </wsdl:types>
> > >>>>>Axis2 code generator is configured to throw an exception if it
> > >>
> > >>encounters a
> > >>
> > >>>>>schema element that does not declare a target namespace. Is that
> > >>
> > >>correct in
> > >>
> > >>>>>this case ?
> > >>>>>--
> > >>>>>Ajith Ranabahu
> > >>>>
> > >>>>
> > >>>>--
> > >>>>-- Jaya
> > >>>>
> > >>>
> > >>>
> > >>>--
> > >>>Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform
> > >>>
> > >>
> > >>
> > >>
> > >>
> > >>--
> > >>Ajith Ranabahu
> > >
> > >
> > >
> >
> 
> 
> --
> Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform
> 


-- 
Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform

Re: [Axis2] Clarification needed on the Types section

Posted by Davanum Srinivas <da...@gmail.com>.
ok. but anyways the bottom line is the wsdl in question (wsrf) is a
valid wsdl with a valid schema and we should not fail.

-- dims

On 8/24/05, Glen Daniels <gl...@thoughtcraft.com> wrote:
> Dims, you can only do that if WSDL says that's what you do (otherwise
> it's not interoperable, or correct according to schema).
> 
> I don't see the problem Sanjiva is worried about, though.  If the
> elements are unqualified, then the references are simply unqualified as
> well... <input element="foo"/> instead of <input element="ns:foo"/> -
> what's the big deal?
> 
> --G
> 
> Davanum Srinivas wrote:
> > Ajith,
> >
> > In Axis 1.X and elsewhere, people default to wsdl's targetNamespace.
> > can't we do that instead?
> >
> > -- dims
> >
> > On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> >
> >>Hi Dims,
> >> I actually discussed this with Sanjiva after going through the specs. He's
> >>in the view that the schema defined in the WSDL needs to have the
> >>targetNamespace attribute even though it is not mandatory according to the
> >>schema spec. The reason is that if the elements are unqualified then the
> >>messages section might have a problem refering to the elements.These facts
> >>do not seem to be documented anywhere :(
> >> However I feel Jaya's solution seems to be valid since it serves the WSDL's
> >>purpose!
> >>
> >> Thoughts ?
> >>
> >>
> >>
> >>On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
> >>
> >>>check the xsd schema's schema. if it is mandatory then throw exception
> >>>if it is absent otherwise don't.
> >>>
> >>>-- dims
> >>>
> >>>On 8/24/05, jayachandra <jayachandra@gmail.com > wrote:
> >>>
> >>>>Ajith!
> >>>>If the content inside the <xsd:schema> element is(are) just an import
> >>>>statement(s) then, I guess, there need not be a targetNamespace.
> >>>>However if any information other than import elements appear (viz.
> >>>>element declarations, include statements etc.) then we should throw
> >>>>that exception. Just my thought, though
> >>>>
> >>>>Thank you
> >>>>Jayachandra
> >>>>
> >>>>On 8/24/05, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> >>>>
> >>>>>Hi all,
> >>>>>the following piece of WSDL is from the WSRF WSDL at
> >>>>>http://docs.oasis-open.org/wsrf/rpw-1
> >>>>>
> >>>>><wsdl:types>
> >>>>> <xsd:schema>
> >>>>> <xsd:import
> >>>>> namespace="http://docs.oasis-open.org/wsrf/rp-1 "
> >>>>> schemaLocation="
> >>>>
> >>>>http://docs.oasis-open.org/wsrf/rp-1" />
> >>>>
> >>>>> </xsd:schema>
> >>>>> </wsdl:types>
> >>>>>Axis2 code generator is configured to throw an exception if it
> >>
> >>encounters a
> >>
> >>>>>schema element that does not declare a target namespace. Is that
> >>
> >>correct in
> >>
> >>>>>this case ?
> >>>>>--
> >>>>>Ajith Ranabahu
> >>>>
> >>>>
> >>>>--
> >>>>-- Jaya
> >>>>
> >>>
> >>>
> >>>--
> >>>Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform
> >>>
> >>
> >>
> >>
> >>
> >>--
> >>Ajith Ranabahu
> >
> >
> >
> 


-- 
Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform

Re: [Axis2] Clarification needed on the Types section

Posted by Glen Daniels <gl...@thoughtcraft.com>.
Dims, you can only do that if WSDL says that's what you do (otherwise 
it's not interoperable, or correct according to schema).

I don't see the problem Sanjiva is worried about, though.  If the 
elements are unqualified, then the references are simply unqualified as 
well... <input element="foo"/> instead of <input element="ns:foo"/> - 
what's the big deal?

--G

Davanum Srinivas wrote:
> Ajith,
> 
> In Axis 1.X and elsewhere, people default to wsdl's targetNamespace.
> can't we do that instead?
> 
> -- dims
> 
> On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> 
>>Hi Dims,
>> I actually discussed this with Sanjiva after going through the specs. He's
>>in the view that the schema defined in the WSDL needs to have the
>>targetNamespace attribute even though it is not mandatory according to the
>>schema spec. The reason is that if the elements are unqualified then the
>>messages section might have a problem refering to the elements.These facts
>>do not seem to be documented anywhere :(
>> However I feel Jaya's solution seems to be valid since it serves the WSDL's
>>purpose!
>> 
>> Thoughts ?
>>
>> 
>>
>>On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
>>
>>>check the xsd schema's schema. if it is mandatory then throw exception
>>>if it is absent otherwise don't.
>>>
>>>-- dims
>>>
>>>On 8/24/05, jayachandra <jayachandra@gmail.com > wrote:
>>>
>>>>Ajith!
>>>>If the content inside the <xsd:schema> element is(are) just an import
>>>>statement(s) then, I guess, there need not be a targetNamespace.
>>>>However if any information other than import elements appear (viz. 
>>>>element declarations, include statements etc.) then we should throw
>>>>that exception. Just my thought, though
>>>>
>>>>Thank you
>>>>Jayachandra
>>>>
>>>>On 8/24/05, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
>>>>
>>>>>Hi all,
>>>>>the following piece of WSDL is from the WSRF WSDL at
>>>>>http://docs.oasis-open.org/wsrf/rpw-1 
>>>>>
>>>>><wsdl:types>
>>>>> <xsd:schema>
>>>>> <xsd:import
>>>>> namespace="http://docs.oasis-open.org/wsrf/rp-1 "
>>>>> schemaLocation="
>>>>
>>>>http://docs.oasis-open.org/wsrf/rp-1" />
>>>>
>>>>> </xsd:schema>
>>>>> </wsdl:types> 
>>>>>Axis2 code generator is configured to throw an exception if it
>>
>>encounters a
>>
>>>>>schema element that does not declare a target namespace. Is that
>>
>>correct in
>>
>>>>>this case ?
>>>>>--
>>>>>Ajith Ranabahu
>>>>
>>>>
>>>>--
>>>>-- Jaya
>>>>
>>>
>>>
>>>--
>>>Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform
>>>
>>
>> 
>>
>>
>>-- 
>>Ajith Ranabahu 
> 
> 
> 

Re: [Axis2] Clarification needed on the Types section

Posted by Davanum Srinivas <da...@gmail.com>.
Sanjiva,

It's not some odd-ball wsdl from a clueless person. It's the WSRF wsdl
(see the email from Ajith -
http://marc.theaimsgroup.com/?l=axis-dev&m=112488538126989&w=2)

I don't believe it is wrong!!!

thanks,
dims

On 8/24/05, Sanjiva Weerawarana <sa...@opensource.lk> wrote:
> On Wed, 2005-08-24 at 09:10 -0400, Davanum Srinivas wrote:
> > Ajith,
> >
> > In Axis 1.X and elsewhere, people default to wsdl's targetNamespace.
> > can't we do that instead?
> 
> That's flat out wrong .. :(. Any normal schema process given a schema
> without a TNS (called chameleon schema IIRC) will consider the declared
> EIIs and AIIs as not being qualified. If they are not qualified it is
> impossible to refer to them from WSDL. Hence its illegal.
> 
> Ajith, can you send your question to the WSDL WG mailing list? There are
> several serious XSD wonks there and we can get the definitive answer
> there.
> 
> Sanjiva.
> 
> 
> 


-- 
Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform

Re: [Axis2] Clarification needed on the Types section

Posted by Sanjiva Weerawarana <sa...@opensource.lk>.
On Wed, 2005-08-24 at 09:10 -0400, Davanum Srinivas wrote:
> Ajith,
> 
> In Axis 1.X and elsewhere, people default to wsdl's targetNamespace.
> can't we do that instead?

That's flat out wrong .. :(. Any normal schema process given a schema
without a TNS (called chameleon schema IIRC) will consider the declared
EIIs and AIIs as not being qualified. If they are not qualified it is
impossible to refer to them from WSDL. Hence its illegal.

Ajith, can you send your question to the WSDL WG mailing list? There are
several serious XSD wonks there and we can get the definitive answer
there.

Sanjiva.



Re: [Axis2] Clarification needed on the Types section

Posted by Davanum Srinivas <da...@gmail.com>.
Ajith,

In Axis 1.X and elsewhere, people default to wsdl's targetNamespace.
can't we do that instead?

-- dims

On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> Hi Dims,
>  I actually discussed this with Sanjiva after going through the specs. He's
> in the view that the schema defined in the WSDL needs to have the
> targetNamespace attribute even though it is not mandatory according to the
> schema spec. The reason is that if the elements are unqualified then the
> messages section might have a problem refering to the elements.These facts
> do not seem to be documented anywhere :(
>  However I feel Jaya's solution seems to be valid since it serves the WSDL's
> purpose!
>  
>  Thoughts ?
> 
>  
> 
> On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
> > check the xsd schema's schema. if it is mandatory then throw exception
> > if it is absent otherwise don't.
> > 
> > -- dims
> > 
> > On 8/24/05, jayachandra <jayachandra@gmail.com > wrote:
> > > Ajith!
> > > If the content inside the <xsd:schema> element is(are) just an import
> > > statement(s) then, I guess, there need not be a targetNamespace.
> > > However if any information other than import elements appear (viz. 
> > > element declarations, include statements etc.) then we should throw
> > > that exception. Just my thought, though
> > >
> > > Thank you
> > > Jayachandra
> > >
> > > On 8/24/05, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> > > > Hi all,
> > > > the following piece of WSDL is from the WSRF WSDL at
> > > > http://docs.oasis-open.org/wsrf/rpw-1 
> > > >
> > > > <wsdl:types>
> > > >  <xsd:schema>
> > > >  <xsd:import
> > > >  namespace="http://docs.oasis-open.org/wsrf/rp-1 "
> > > >  schemaLocation="
> > > http://docs.oasis-open.org/wsrf/rp-1" />
> > > >  </xsd:schema>
> > > >  </wsdl:types> 
> > > > Axis2 code generator is configured to throw an exception if it
> encounters a
> > > > schema element that does not declare a target namespace. Is that
> correct in
> > > > this case ?
> > > > --
> > > > Ajith Ranabahu
> > >
> > >
> > > --
> > > -- Jaya
> > >
> > 
> > 
> > --
> > Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform
> > 
>  
> 
> 
> -- 
> Ajith Ranabahu 


-- 
Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform

Re: [Axis2] Clarification needed on the Types section

Posted by Ajith Ranabahu <aj...@gmail.com>.
Hi Dims,
I actually discussed this with Sanjiva after going through the specs. He's 
in the view that the schema defined in the WSDL needs to have the 
targetNamespace attribute even though it is not mandatory according to the 
schema spec. The reason is that if the elements are unqualified then the 
messages section might have a problem refering to the elements.These facts 
do not seem to be documented anywhere :(
However I feel Jaya's solution seems to be valid since it serves the WSDL's 
purpose!

Thoughts ?


On 8/24/05, Davanum Srinivas <da...@gmail.com> wrote:
> 
> check the xsd schema's schema. if it is mandatory then throw exception
> if it is absent otherwise don't.
> 
> -- dims
> 
> On 8/24/05, jayachandra <ja...@gmail.com> wrote:
> > Ajith!
> > If the content inside the <xsd:schema> element is(are) just an import
> > statement(s) then, I guess, there need not be a targetNamespace.
> > However if any information other than import elements appear (viz.
> > element declarations, include statements etc.) then we should throw
> > that exception. Just my thought, though
> >
> > Thank you
> > Jayachandra
> >
> > On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> > > Hi all,
> > > the following piece of WSDL is from the WSRF WSDL at
> > > http://docs.oasis-open.org/wsrf/rpw-1
> > >
> > > <wsdl:types>
> > > <xsd:schema>
> > > <xsd:import
> > > namespace="http://docs.oasis-open.org/wsrf/rp-1"
> > > schemaLocation="
> > http://docs.oasis-open.org/wsrf/rp-1" />
> > > </xsd:schema>
> > > </wsdl:types>
> > > Axis2 code generator is configured to throw an exception if it 
> encounters a
> > > schema element that does not declare a target namespace. Is that 
> correct in
> > > this case ?
> > > --
> > > Ajith Ranabahu
> >
> >
> > --
> > -- Jaya
> >
> 
> 
> --
> Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform
> 



-- 
Ajith Ranabahu

Re: [Axis2] Clarification needed on the Types section

Posted by Davanum Srinivas <da...@gmail.com>.
check the xsd schema's schema. if it is mandatory then throw exception
if it is absent otherwise don't.

-- dims

On 8/24/05, jayachandra <ja...@gmail.com> wrote:
> Ajith!
> If the content inside the <xsd:schema> element is(are) just an import
> statement(s) then, I guess, there need not be a targetNamespace.
> However if any information other than import elements appear (viz.
> element declarations, include statements etc.) then we should throw
> that exception. Just my thought, though
> 
> Thank you
> Jayachandra
> 
> On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> > Hi all,
> > the following piece of WSDL is from the WSRF WSDL at
> > http://docs.oasis-open.org/wsrf/rpw-1
> >
> > <wsdl:types>
> >  <xsd:schema>
> >  <xsd:import
> >  namespace="http://docs.oasis-open.org/wsrf/rp-1"
> >  schemaLocation="
> http://docs.oasis-open.org/wsrf/rp-1" />
> >  </xsd:schema>
> >  </wsdl:types>
> > Axis2 code generator is configured to throw an exception if it encounters a
> > schema element that does not declare a target namespace. Is that correct in
> > this case ?
> > --
> > Ajith Ranabahu
> 
> 
> --
> -- Jaya
> 


-- 
Davanum Srinivas : http://wso2.com/ - Oxygenating The Web Service Platform

Re: [Axis2] Clarification needed on the Types section

Posted by jayachandra <ja...@gmail.com>.
Ajith!
If the content inside the <xsd:schema> element is(are) just an import
statement(s) then, I guess, there need not be a targetNamespace.
However if any information other than import elements appear (viz.
element declarations, include statements etc.) then we should throw
that exception. Just my thought, though

Thank you
Jayachandra

On 8/24/05, Ajith Ranabahu <aj...@gmail.com> wrote:
> Hi all,
> the following piece of WSDL is from the WSRF WSDL at
> http://docs.oasis-open.org/wsrf/rpw-1
> 
> <wsdl:types>
>  <xsd:schema>
>  <xsd:import
>  namespace="http://docs.oasis-open.org/wsrf/rp-1" 
>  schemaLocation="
http://docs.oasis-open.org/wsrf/rp-1" />
>  </xsd:schema>
>  </wsdl:types>
> Axis2 code generator is configured to throw an exception if it encounters a
> schema element that does not declare a target namespace. Is that correct in
> this case ?
> -- 
> Ajith Ranabahu 


-- 
-- Jaya