Subject: Re: Created proposal: PaceProvideSchema

From: Randy Charles Morin <[email-masked]>
Date: Sat, 10 Jul 2004 20:35:26 -0700 (PDT)

>That would be unacceptable, the schema and 
>the prose have to be consistent. -Tim
 
Atom would have to be substantially rewritten to make this plausible. 
 
Case #1. You cannot account for cardinality of unordered elements in the feed and entry. This is simply not possible in XSD. There would have to be inconsistency somewhere.
 
Case #2. The content element is not expressible in XSD.
 
Thanks and have a nice day,
 
Randy
http://www.kbcafe.com

---------------------------------
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!

---

From: Asbjørn Ulsberg <[email-masked]>
Date: Sun, 11 Jul 2004 16:38:06 +0200

On Sat, 10 Jul 2004 20:35:26 -0700 (PDT), Randy Charles Morin  
<[email-masked]> wrote:

> Case #1. You cannot account for cardinality of unordered elements in the  
> feed and entry. This is simply not possible in XSD. There would have to  
> be inconsistency somewhere.

That's understandable. This is imho a flaw in XSD, though.

> Case #2. The content element is not expressible in XSD.

What do you mean, «not expressible»? Isn't it possible to say 'xs:anyType'  
with any namespace to be the the child of atom:content, or is it something  
else that is impossible to express?

-- 
Asbjørn Ulsberg         -=|=-        [email-masked]
«He's a loathsome offensive brute, yet I can't look away»

---

From: Randy Charles Morin <[email-masked]>
Date: Sun, 11 Jul 2004 08:14:11 -0700 (PDT)

>That's understandable. This is imho a flaw in XSD, though.
 
No, it is a feature. Writing a validator that accounts for cardinality of ordered elements is substantially more difficult.

>else that is impossible to express?
 
Correct. Let me rephrase. You cannot accurately express contentType such that tools like XSD.exe can generate the corresponding data model, without some loss of type definition.
Thanks,
 
Randy
http://www.kbcafe.com

---------------------------------
Do you Yahoo!?
Yahoo! Mail - 50x more storage than other providers!

---

From: Asbjørn Ulsberg <[email-masked]>
Date: Sun, 11 Jul 2004 18:01:40 +0200

On Sun, 11 Jul 2004 08:14:11 -0700 (PDT), Randy Charles Morin  
<[email-masked]> wrote:

> No, it is a feature. Writing a validator that accounts for cardinality  
> of unordered elements is substantially more difficult.

Does RNG have this restrictive «feature» as well?

> You cannot accurately express contentType such that tools like XSD.exe
> can generate the corresponding data model, without some loss of type
> definition.

What is «loss of type definition», then? How serious is it? What's lost,  
exactly?

---

From: Norman Walsh <[email-masked]>
Date: Sun, 11 Jul 2004 12:09:35 -0400

/ Randy Charles Morin <[email-masked]> was heard to say:
|>That would be unacceptable, the schema and 
|>the prose have to be consistent. -Tim
|
| Atom would have to be substantially rewritten to make this plausible. 
|
| Case #1. You cannot account for cardinality of unordered elements in the feed and entry. This is simply not possible in XSD. There would have to be inconsistency somewhere.
|
| Case #2. The content element is not expressible in XSD.

Uhm. So don't use XSD?

                                        Be seeing you,
                                          norm

-- 
Norman Walsh <[email-masked]> | Man is the only animal who causes pain
http://nwalsh.com/            | to others with no other object than
                              | wanting to do so.-- Schopenhauer

---

From: Randy Charles Morin <[email-masked]>
Date: Sun, 11 Jul 2004 09:47:32 -0700 (PDT)

>Does RNG have this restrictive «feature» as well?
 
Good question. Anybody know the answer? Regardless, RNG is not supported by many developer tools [1]. 

>What is «loss of type definition», then? 
>How serious is it? What's lost, exactly?

I'll describe two losses present in my Atom XSD [2].
 
#1 - The schema, run thru XSD.exe [3] or WSDL.exe [4] to generate C#, does not limit the amount of title elements present within a feed or entry element. This is because of the limitation above.
 
#2 - In my attempt to describe the content multipart/alternative construct in XSD, the XSD.exe tool complained saying that the XSD is not deterministic. That's because the content element has two possible parents, one of which is itself.
Thanks and hope this helps,
 
Randy
http://www.kbcafe.com
 
[1] - http://www.relaxng.org/#code-generators
[2] - http://www.kbcafe.com/rss/?guid=20040710135750
[3] - http://msdn.microsoft.com/library/en-us/cptools/html/cpconXMLSchemaDefinitionToolXsdexe.asp
[4] - http://msdn.microsoft.com/library/en-us/cptools/html/cpgrfWebServicesDescriptionLanguageToolWsdlexe.asp

---

From: Mark Nottingham <[email-masked]>
Date: Sun, 11 Jul 2004 17:45:58 -0700

> Uhm. So don't use XSD?

Big +1

Mark Nottingham     http://www.mnot.net/

---

From: James M Snell <[email-masked]>
Date: Sun, 11 Jul 2004 21:56:50 -0600

-1 on this.  Those of us who care about XML Schema should provide an XML 
Schema... not for normative purposes, however.  Those who care about Relax 
should provide a Relax thing.  Let's not rule such things out simply 
because of our personal feelings about various technologies or the 
companies who promote them.  There are sound technical reasons why some 
folks may want an XSD.  I am not saying it should be codified as part of 
the Atom specification, but something could and should be made available.

- James M Snell
  [email-masked]
  http://www.ibm.com
  (877) 511-5082 / Office
  930-1979 / Tie Line

Mark Nottingham <[email-masked]> 
Sent by: [email-masked]
07/11/2004 05:45 PM

To
Norman Walsh <[email-masked]>
cc
Atom Syntax <[email-masked]>
Subject
Re: Created proposal: PaceProvideSchema

Big +1

---

From: Mark Nottingham <[email-masked]>
Date: Sun, 11 Jul 2004 21:17:40 -0700

To be clear -

I have no problem with providing an XML Schema; it is a genuinely 
useful thing to provide for some people. In fact, I'd be disappointed 
if we didn't provide one.

However, it shouldn't be normative, for reasons described before, and 
the design of Atom shouldn't be subjugated by the needs of Schema; if 
there's contention between real-world requirements and the contortions 
that Schema makes you go through, Schema should lose (i.e., the schema 
should be less expressive).

That's what I meant by +1'ing "not using XML Schema" -- apologies if 
that wasn't clear.

Cheers,

On Jul 11, 2004, at 8:56 PM, James M Snell wrote:

> -1 on this.  Those of us who care about XML Schema should provide an 
> XML Schema... not for normative purposes, however.  Those who care 
> about Relax should provide a Relax thing.  Let's not rule such things 
> out simply because of our personal feelings about various technologies 
> or the companies who promote them.  There are sound technical reasons 
> why some folks may want an XSD.  I am not saying it should be codified 
> as part of the Atom specification, but something could and should be 
> made available.

---

From: Bill de hÓra <[email-masked]>
Date: Mon, 12 Jul 2004 15:31:58 +0100

> should be less expressive).

I don't' understand why Mark is having to labour this point. It's 
normal that specs with ebnf, logic or something equally precise go 
out where the prose is the last word when the ebnf, logic or 
something else isn't adequate. Why would schemata be any different?

On the other hand, I would like to see which structural constraints 
of Atom can't be expressed or can't be expressed easily by RNG or 
Schematron*, as opposed to predictions and assumptions. The ones I'm 
aware of are element ordering and 'extensibility' spots such as 
@rel. Apart from mild skepticism, such constraints are an ideal 
point of departure for conformance tests.

As an aside. The issue with non-normative schemata is that people 
drop them into their normative systems and are often disappointed at 
the outcome. When this matter comes onto the work list, we should 
expect to see big friendly letters nearby warning people what they 
may and may not assume about the schema.

Thus:

+1 to a schema in the spec. I don't care whether it's normative of not.

+1 to using RNG for this purpose. I don't care whether it's XML or 
compact format.

-1 to not tracking the schema across editions of the specs.  If 
schemata seem to be valuable, then they seem to me to be constantly 
valuable. I have no problem doing this, nor it seems do others.

cheers
Bill

* DTD/WXS I'll exclude due to their limited power of expression. Yes 
I know the tool support is better.

---

From: James M Snell <[email-masked]>
Date: Mon, 12 Jul 2004 10:25:24 -0600

:-) No problem there.  +1 on NOT requiring the XSD Schema to be normative.

- James M Snell
  [email-masked]
  http://www.ibm.com
  (877) 511-5082 / Office
  930-1979 / Tie Line

07/11/2004 09:17 PM

To
James M Snell/Fresno/IBM@IBMUS
cc
Atom Syntax <[email-masked]>, [email-masked], Norman 
Walsh <[email-masked]>
Subject
Re: Created proposal: PaceProvideSchema

To be clear -

Cheers,