You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@axis.apache.org by Aleksander Slominski <as...@cs.indiana.edu> on 2004/06/02 09:20:40 UTC

curious bug with namespace prefixes

i would suggest to use something more than string concatentaion to emit 
XML output with namesapces (i had similiar problems in XSOAP1).

otherwise one can get such invalid XML produced by AXIS-C++ (prefix 
SOAP-ENV is not declared ...)

<?xml version='1.0' encoding='utf-8' ?><env:Envelope 
xmlns:env=\"http://www.w3.org/2003/05/soap-envelope\" 
xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" 
xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"><env:Body><SOAP-ENV:Fault><faultcode 
xsi:type=\"xsd:string\">SOAP-ENV:Client</faultcode><faultstring 
xsi:type=\"xsd:string\">Soap method is not allowed to 
invoke</faultstring><faultactor 
xsi:type=\"xsd:string\">http://endpoint/url</faultactor><faultdetail 
xsi:type=\"xsd:string\">Requested method is not 
allowed</faultdetail></SOAP-ENV:Fault></env:Body></env:Envelope>---

something like Tim Bray serializer (see xml-dev) or XmlPull 
XmlSerializer (but translated to C++ ) should make writing valid XML 
much easier.

alek

-- 
The best way to predict the future is to invent it - Alan Kay


Re: curious bug with namespace prefixes

Posted by Roshan Weerasuriya <ro...@opensource.lk>.
hi alek,

 >otherwise one can get such invalid XML produced by AXIS-C++ (prefix 
SOAP-ENV is not declared ...)

Fixed it. The prefix "SOAP-ENV" was hard-coded in the Axis C++ code. 
Corrected it now.

rgds,
Roshan

At 02:20 AM 6/2/2004 -0500, you wrote:
>i would suggest to use something more than string concatentaion to emit 
>XML output with namesapces (i had similiar problems in XSOAP1).
>
>otherwise one can get such invalid XML produced by AXIS-C++ (prefix 
>SOAP-ENV is not declared ...)
>
><?xml version='1.0' encoding='utf-8' ?><env:Envelope 
>xmlns:env=\"http://www.w3.org/2003/05/soap-envelope\" 
>xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" 
>xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"><env:Body><SOAP-ENV:Fault><faultcode 
>xsi:type=\"xsd:string\">SOAP-ENV:Client</faultcode><faultstring 
>xsi:type=\"xsd:string\">Soap method is not allowed to 
>invoke</faultstring><faultactor 
>xsi:type=\"xsd:string\">http://endpoint/url</faultactor><faultdetail 
>xsi:type=\"xsd:string\">Requested method is not 
>allowed</faultdetail></SOAP-ENV:Fault></env:Body></env:Envelope>---
>
>something like Tim Bray serializer (see xml-dev) or XmlPull XmlSerializer 
>(but translated to C++ ) should make writing valid XML much easier.
>
>alek
>
>--
>The best way to predict the future is to invent it - Alan Kay
>