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

[SOAP Encoding Issue] Multi-reference 'id' attribute - NOT a real ID

From: Asir S Vedamuthu <asirv@webmethods.com>
Date: Mon, 15 Oct 2001 16:34:02 -0400
Message-ID: <06dc01c155b8$b9cbf720$883c010a@webmethods.com>
To: <xml-dist-app@w3.org>
Issue

Unqualified attribute named 'id' and of type 'ID' per the XML 1.0
specification DOES NOT MEAN that it is of type ID !!

Part 2, Section 4.1 'Rules for Encoding Types in XML' [1], rule 5 says that
a multi-reference value is encoded as an independent element containing a
local, unqualified attribute named 'id' and of type 'ID' per the XML 1.0
specification.

Part 2, Section 2 'Relation to XML' [2] says that a SOAP message MUST NOT
contain a Document Type Declaration (DTD).

[From Processing Model Workshop] In general, XML processes can be classified
into two categories: bootstrap and application processes. XML Information
Set is the basic unit of processing. Bootstrap process comes first.
Bootstrap process applies processing rules from XML 1.0, XML Namespaces and
XML Base. XML Information Set is available after bootstrapping.

During the bootstrap processing, if there is a DTD, the bootstrap process
will consume it. It is the DTD that tells the bootstrap process that 'id'
attribute is of type XML 1.0 ID. A SOAP message cannot contain a DTD and ID
processing never happens.

A schema document MAY be used to describe the payload. This schema may
describe that an unqualified attribute named 'id' is of type 'ID'. But,
schema does not play a role in the bootstrap process. And, SOAP does not
mandate using a schema aware processor, post-schema-validation-infoset and
[ID / IDREF table] [3]

Lets say a SOAP decoder uses DOM Level 2 Core API to traverse a SOAP
message. Decoder will use the [4] Document.getElementById(in DOMString
elementId); DOM specifies one constraint on this method - "The DOM
implementation must have information that says which attributes are of type
ID. Attributes with the name "ID" are not of type ID unless so defined.
Implementations that do not know whether attributes are of type ID or not
are expected to return null"

The conclusion here is that multi-reference representation's 'id' attribute
is not a real XML 1.0 ID. This means,

(a) Implementations must use additional code to simulate XML 1.0 ID
(b) It fails to satisfy Usage Scenario S21 [5]. 'Cos, implementations must
parse the entire document to construct an id and bearing element information
item table.

[1] http://www.w3.org/TR/2001/WD-soap12-part2-20011002/#encrules
[2] http://www.w3.org/TR/2001/WD-soap12-part2-20011002/#reltoxml
[3] http://www.w3.org/TR/2001/REC-xmlschema-1-20010502/#sic-id
[4] http://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-getElBId
[5] http://www.w3.org/TR/2001/WD-xmlp-reqs-20010319/#S21

Regards,

Asir S Vedamuthu

webMethods, Inc.
703-460-2513 or asirv@webmethods.com
http://www.webmethods.com/
Received on Monday, 15 October 2001 16:29:17 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:59:04 GMT