Subject: [ippm] [store traceroutes] Value of maxOccurs too big in the schema?

From: Stephane Bortzmeyer <[email-masked]>
Date: Wed, 19 Nov 2008 16:17:44 +0100

I tried to use libxml's xmllint checker with the schema of
store-traceroutes-12 and it fails:

traceroute.xsd:658: element element: Schemas parser error : Element
 '{http://www.w3.org/2001/XMLSchema}element', attribute 'maxOccurs': The value
 '4294967295' is not valid. Expected is '(xs:nonNegativeInteger | unbounded)'.

[This is in:
           <xs:element maxOccurs="4294967295" minOccurs="0"
                       name="Measurement">
]

Searching if the schema or xmllint was wrong, I discovered that the
standard does not put limits to maxOccurs:

http://www.w3.org/TR/2004/REC-xmlschema-1-20041028/structures.html#p-max_occurs 
http://www.w3.org/TR/2004/REC-xmlschema-2-20041028/datatypes.html#nonNegativeInteger

The standard says "The value space of nonNegativeInteger is the
infinite set {0,1,2,...}."

Nevertheless, I do not think that many W3C XML Schema implementors
used unsigned 32bits or 64bits integers (or bigints) for the value of
maxOccurs and I wonder if this value is reasonable (specially since
there is little perspective of 4294967295 <Measurement>...).

Would'nt it be better to use maxOccurs="2147483647" or "unbounded"?

[I know, the draft is in the RFC editor queue...]
_______________________________________________
ippm mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/ippm