axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tony Opatha <topa...@yahoo.com>
Subject RE: xmlns=" " in the doc\literal SOAP message
Date Fri, 05 Sep 2003 18:45:27 GMT
This bug was logged in May it seems. Furthermore, this seems to imply that
a patch became available. However, there is a problem pertaining to this using
AXIS 1.1 Final and I am not sure this problem is *only* manifesting itself in
the case when we attempt to interoperate with .NET WSE.
 
I think again the problem is that AXIS should NOT explicitly place the 
xmlns=".... attribute as part of a sub-element of the document instance
that is serialized as part of the SOAP Body if that sub-element belongs
to an imported namespace which is declared in the document schema
as one of the namespaces used by the document.
 
Is there any workaround to this problem? 
 
Thanks


Cory Wilkerson <cwilkerson@travelnow.com> wrote:
See: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19524
-----Original Message-----
From: Tony Opatha [mailto:topatha@yahoo.com]
Sent: Friday, September 05, 2003 12:13 PM
To: axis-user@ws.apache.org
Subject: RE: xmlns=" " in the doc\literal SOAP message



>Since elementFormDefault is "qualified" -- then one could safely assume that since >Axis
generated this wsdl, it should also be serializing local elements in the appropriate >namespace...NOT
adding xmlns="".

Is there any workaround for this currently? 

That is exactly the problem I was identifying in AXIS previously (see below). If the elementFormDetail
is qualified then we should not see explictly xmlns attributes in each element rather the
namespace prefix should qualify the element that is part of the document instance in the SOAP
Body. 

This is especially problematic when we import additional schema from other namespaces and
declare them in the document schema that will serialized as part of the SOAP Body by AXIS.
I have observed that if you use directly AXIS SOAP APIs to serialize the payload using the
XSD schema this beahviour does not happen (if you set the QNames properly..), but it is jot
the case using the AXIS messaging pipeline (the conventional way of processing SOAP payloads
using WSDL). 

>>Is there a way in AXIS to support only inclusion of namespace prefix for elements
that
>>are defined in a namespace that is not the default namespace rather than explcitly
>>including the complete i.e., fully qualified namespace for each sub-element of the
>>document instance that is included in the SOAP Body?
>>
>>I would presume that either based on the XSD schema spec of the document and/or
>>the WSDL interface spec AXIS would be able to use the namespace prefix to identify
>>that a particular element is associated in a particular namespace.


Anne Thomas Manes <anne@manes.net> wrote: Cory,

You're correct. Please file a bug report.

Anne

At 10:05 AM 9/5/2003 -0500, you wrote:
>I think I now know what the source of Dimuthu's problem was/is -- I've 
>generated a doc/lit service in Axis and the schema that Axis generates for 
>a given service indicates that the elementFormDefault is qualified, ie:
>
>
> > targetNamespace="http://test.xml.travelnow.com" elementFormDefault="qualified">
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
! > 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>
>
>As a response to this service, Axis generates the following (and IMHO, 
>wrong) response:
>
>
>>xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" 
>xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
>xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
> 
> 

> 
CORY

> 

> 
>
>
>S! ince elementFormDefault is "qualified" -- then one could safely assume 
>that since Axis generated this wsdl, it should also be serializing local 
>elements in the appropriate namespace...NOT adding xmlns="". One would 
>also assume that client tools parsing this WSDL would expect to see 
>"processReturn" serialized in the "http://test.xml.travelnow.com" namespace.
>
>Thanks again!
>Cory Wilkerson
>
>
>-----Original Message-----
>From: Anne Thomas Manes [mailto:anne@manes.net]
>Sent: Tuesday, September 02, 2003 8:40 AM
>To: axis-user@ws.apache.org
>Subject: Re: xmlns=" " in the doc\literal SOAP message
>
>
>Dimuthu,
>
>Yes. It's okay for empty namespace definitions to go across the wire. In
>fact, it some cases it might be required.
>
>In your SOAP request, the element defines a default namespace
>(xmlns="blah" as opposed to xmlns:foo="! blah"), which then applies to all
>subelements of the element, unless it is overridden by another
>default namespace definition. If the and elements
>are local elements to , then they should not be namespace qualified,
>and in that case, you should specify an empty default namspace definition
>in each of these subelements to override the active default namespace.
>
>Now, if the and are global elements, then this
>message would be in error.
>
>So whether or not this message is correct depends on the schema definition
>for the message.
>
>Anne
>
>At 02:20 AM 9/1/2003 -0700, you wrote:
> >Hi all,
> >
> >I'm trying to write a doc\literal web service and my soap message appears
> >as below.........
> >
> >
> > Wood carving of! an Elephant
> > ER234
> >
> >
> >Has anybody else has come across a situation like this? Is it ok for empty
> >xmlns="" tags to go in the wire? Any help is greatly appreciated.
> >
> >Thank you,
> >Dimuthu
> >
> >
> >Do you Yahoo!?
> >Yahoo!
> >SiteBuilder - Free, easy-to-use web site design software




---------------------------------
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software

---------------------------------
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
Mime
View raw message