[AWS] SOAP...Load_Payload can't parse SOAP message header element

Marc Criley mc at mckae.com
Fri Jul 13 21:08:34 CEST 2007


(I'm actually working with two versions of AWS, the GNAT GPL version on a Linux
box, and version 2.0p on the Silicon Graphics, which still uses GNAT 3.17w.)

This issue occurs in AWS 2.0, and may be fixed in a later version--I don't have
the means to check that at the present time.

SOAP.Message.XML.Load_Payload fails when the SOAP document contains a Header element.

This first document is successfully processed by Load_Payload (it is what is
produced by the soap_client demo):

<?xml version='1.0' encoding='UTF-8'?>
<SOAP-ENV:Envelope
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance">
<SOAP-ENV:Body>
<awsns:This_Proc xmlns:awsns="http://mns.org/">
<p1 xsi:type="xsd:int">10</p1>
<p2 xsi:type="xsd:int">32</p2>
<p3 xsi:type="xsd:float">12.40000000000000</p3>
</awsns:This_Proc>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

This document causes Load_Payload to fail (it was produced by a Java client using
the SAAJ classes):

<?xml version="1.0" encoding="utf-8" ?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/encoding/">
<SOAP-ENV:Header/>
<SOAP-ENV:Body>
<awsns:This_Proc xmlns:awsns="http://mns.org/">
<p1 xsi:type="xsd:int">10</p1>
<p2 xsi:type="xsd:int">32</p2>
<p3 xsi:type="xsd:float">12.40000000000000</p3>
</awsns:This_Proc>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

The presence of absence of the Header element governs whether Load_Payload
processes it successfully or not.

-- Marc A. Criley
-- McKae Technologies
-- www.mckae.com
-- Avatox - DTraq - XML EZ Out



More information about the AWS mailing list