[RFC] SRS Section 2

Hui Zhou zhouhui at wam.umd.edu
Thu Feb 3 14:19:22 PST 2005


On Thu, Feb 03, 2005 at 09:17:22PM +0000, Matthew Burgess wrote:
>Hui Zhou wrote:
>
>>If it is a random XML file, one should hope it gets rejected because the 
>>server shouldn't understand it. On the other hand, if the server 
>>understands it, more than not it is a correct valid profile even though 
>>the profile may not be dtd compliant. An example is HTML. Most web 
>>browser accepts non-standard compliant html, does the user really care? 
>>No, as long as it looks all right.
>
>Hui, please read the XML spec regarding what the terms "well-formed" and 
>"valid" mean.  

You suggest me reading that l-e-n-g-t-h-y spec again! :-{

>I still have a hard time understanding how the server can 
>possibly be made to understand a profile that isn't valid according to 
>the DTD.  

Lets see what is the reason for a dtd to exist. XML is designed mainly 
if not only for the possibility of general document sharing, the 
biggest value of XML is its ubiquity, in term of XML library or tools 
in any platform and languages. DTD is just another effort to implement 
a general way to validate an XML document. Same with XSLT, XPATH, each 
creates a new lanaguage to describe a general approach toward xml.

Being general is good considering that people can share the document 
even without have the tool that understands the data.

The origianl alfs dtd was created in this thought, that multiple 
implementation of alfs can share the same effort of writing profiles. 
At the time, there was perllfs and nALFS, and I guess they forsee even 
more people will create more implementations. 

In fact, there is no such thing as a person will need a profile but 
without a tool that understands the data. And infact there is very 
limited sharing at all. The effort of maintain the sharability between 
differen applications is simply wasteful.

>After all, it's the DTD (or other schema syntax) that tells 
>the server (and the profile writer) what it should be able to 
>understand.  

Are you talking about a "general" server that don't understand the 
profile data?  As for profile writer, read the documentation! That's 
the way we learn to write profile/configurations for any programs in 
our system.

>What do you propose the server do with a tag like 
>"<bankaccount>" or "<banana>" for example?  

Ignore.

>If the server is presented 
>with something like this it has to bail out because the profile author 
>obviously intended those tags to do something, but the server doesn't 
>know how to handle them.  

Is that your philosophy? I spoke some chinese to you and you don't 
understand and you just stand there "bail out"?

>Even bailing out, is in itself an action taken 
>because the server validated the profile - i.e. it parsed the profile 
>and reached a tag it didn't understand and said to itself "this isn't 
>valid, I'm going to tell the user they've screwed up somewhere".

On bad profile, validated one or not, the server is supposed to bail 
out, and the server is supposed to tell the user why he bailed out.

Say under download tag is a invalid url, does that mean the server 
should not bail out because it is been validated.
>
>>And the validataion won't help much on ensure a correct profile. Most 
>>deadly mistakes are typos in commands such as "rm -r /", not those 
>>unmatching tags. Validation just won't help in most situations.
>
>Agreed, but at least if we can catch one class of errors it's one less 
>frustration for the user than presumably silently ignoring profile 
>errors, which is what you appear to be suggesting.

Have you read the one I replied to Kevin? (Not meant to critcise. If 
you have read it, I won't repeat it here. I will think of other way to 
explain it.:)).

Regards,
-- 
Hui Zhou



More information about the alfs-discuss mailing list