ws-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (Commented) (JIRA)" <>
Subject [jira] [Commented] (AXIOM-114) Soap envelope rpc-encoded namespace issue
Date Fri, 24 Feb 2012 04:17:48 GMT


Hudson commented on AXIOM-114:

Integrated in Axis2 #1271 (See [])
    Adapted to change in Axiom (related to AXIOM-114). (Revision 1292971)

     Result = ABORTED
veithen : 
Files : 
* /axis/axis2/java/core/trunk/modules/xmlbeans/src/org/apache/axis2/xmlbeans/template/XmlbeansDatabindingTemplate.xsl

> Soap envelope rpc-encoded namespace issue 
> ------------------------------------------
>                 Key: AXIOM-114
>                 URL:
>             Project: Axiom
>          Issue Type: Bug
>    Affects Versions: 1.2.8
>         Environment: java 1.6
>            Reporter: Luca Cavanna
>            Assignee: Andreas Veithen
>             Fix For: 1.2.13
>         Attachments:,, soaprequest.xml
> I have replaced saaj with axiom in my projects to manage soap handling.
> I have an rpc-encoded soap envelope containing the declarations of soapenv (xmlns:soapenv="")
and xsi (xmlns:xsi="") namespaces. 
> The first element of the soap body references soapenv in one of his attributes (soapenv:encodingStyle="").
Some xml elements in the soap body reference the xsi namespace (xsi:type="soapenc:string")
as well.
> When I try to parse the soap body (extracted from the soap envelope) using JDOM or DOM4J
I get a SaxParseException because the soapenv and xsi namespaces are not bound:
> org.xml.sax.SAXParseException: The prefix "soapenv" for attribute "soapenv:encodingStyle"
associated with an element type "ns1:sendMessage" is not bound.
> Saaj handles correctly the soapenv and and xsi declarations moving them in the soap body;
with axiom the soap body contain only the reference to those namespaces and not the declarations.
> The issue seems to be creating a StAXSource from Axiom payload element (obtained by calling
axiomSoapMessage.getSOAPEnvelope().getBody().getFirstElement()); serializing payload calling
serialize method namespace are correctly handled, but
> creating a StAXSource using XMLStreamReader and transforming it to a StreamResult I get
an xml not parseable because namespaces are not bound.
> I have found a workaround transforming the StAXSource in a JDOMResult.
> The problem rises when you create a StAXSource from an Axiom payload element (calling
axiomSoapMessage.getSOAPEnvelope().getBody().getFirstElement()). When you call the serialize
method, namespaces are correctly handled; but if you create a StAXSource using an XMLStreamReader
and try to transform it to a StreamResult you get the SaxParseException mentioned above.
> I have found a workaround transforming the StAXSource in a JDOMResult.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message