W3C home > Mailing lists > Public > xml-dist-app@w3.org > December 2001

Proposed Issue 173 Resolution (Hierarchical Fault Codes)

From: Marc Hadley <marc.hadley@sun.com>
Date: Thu, 13 Dec 2001 13:14:01 +0000
Message-ID: <3C18A999.8080502@sun.com>
To: "'xml-dist-app@w3.org'" <xml-dist-app@w3.org>
On last nights WG conference call I took an action to propose a
resolution to issue 173[1]. The proposal presented here is intended as
a friendly ammendment to the resolution proposed in Henrik's mail[2] 
much of whose content is included here for completeness. The changes are 
the result of making the "sub" fault hierarchical (as agreed on the 
call) by merging in the initial hierarchical proposal from Martin Gudgin[3].

The proposed resolution is as follows:

1) We add a subcode child element to the existing SOAP faultcode (not 
the fault) element.

An example Fault element part of a SOAP envelope is:

   <faultcode value="soap-env:Client">
     <subcode xmlns:rpc="..." value="rpc:BadArguments">
       <subcode xmlns:app="..." value="app:MissingArgument"/>

The schema description looks something like:

<xs:complexType name="subcodeType" >
     <xs:element name="subcode" type="tns:subcodeType" minOccurs="0" />
   <xs:attribute name="value" type="xs:QName" use="required" />

<xs:simpleType name="faultcodeenum">
   <xs:restriction base="xs:QName">
     <xs:enumeration value="tns:DataEncodingUnknown" />
     <xs:enumeration value="tns:MustUnderstand" />
     <xs:enumeration value="tns:VersionMismatch" />
     <xs:enumeration value="tns:Sender" />
     <xs:enumeration value="tns:Receiver" />

<xs:complexType name="faultcodeType" >
     <xs:element name="subcode" type="tns:subcodeType" minOccurs="0" />
   <xs:attribute name="value" type="tns:faultcodeenum" use="required" />

2) We enforce that the "value" of <faultcode> is defined by the SOAP
1.2 part 1 specification; that is, it contains one of the status codes
defined by the faultcodeenum above.

3) Given that the encodingStyle attribute is defined in SOAP 1.2 part 1,
the proposal is to leave the DataEncodingUnknown faultcode in part 1
(there was some discussion about this point).

4) <subcode> elements are optional and if included their
"value" is defined by the application using any namespace *other* than
the namespace containing the SOAP part 1 fault codes. The "value" of
a <subcode> is used to refine the parent element's "value".

5) The "sub" fault code(s) can be used to carry both body fault codes
*and* header fault codes - it is *not* limited to body faults.

6) The <faultstring> is still a "human readable string" not intended for
automatic processing. There is only one such element.

7) No other parts of the SOAP Fault are changed.

[1] http://www.w3.org/2000/xp/Group/xmlp-issues.html#x173
[2] http://lists.w3.org/Archives/Public/xml-dist-app/2001Dec/0000.html
[3] http://lists.w3.org/Archives/Public/xml-dist-app/2001Nov/0017.html

Comments, flames etc ?


Marc Hadley <marc.hadley@sun.com>
XML Technology Centre, Sun Microsystems.
Received on Thursday, 13 December 2001 08:16:37 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 22:01:17 UTC