axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <morten.fr...@nordea.dk>
Subject [AXIS2] addHeader problem
Date Fri, 26 Oct 2007 10:29:25 GMT
Hi,

I had a thread going regarding (missing) attributes in a SOAP header
block.

Now I pinned the problem down to the following:

1) In the generated stub class the Object representing the header block
is build in the method org.apache.axiom.om.OMElement toOM(...)

The result of this is an element that when printed has the correct
structure:
<metadata xmlns="http://metadata.ntpsoa.nordea.com/object"
schemaVersion="1.0">....

Here the attribute schemaVersion is generated into the XML fragment
correctly.

2) After the element is built the header is added to the envelope:
addHeader(omElementmetadata1, env);

3) If the header is investigated immediate after this:
System.out.println(env.getHeader().toString());

the result is disappointing:
<soapenv:Header
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><metadata
xmlns="http://metadata.ntpsoa.nordea.com/object"
soapenv:mustUnderstand="0">...


So it seams, that the org.apache.axis2.client.Stub.addHeader method
overwrites the attributes part of the header block, or?

BR
Morten

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


Mime
View raw message