[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Postel's Law Has No Exceptions


postel be conservative
At 05:02 PM 8/19/2003, Simon St.Laurent wrote:
>From:
>http://www.aaronsw.com/weblog/001025
>
>"This is not to say that all apps should have to process invalid
>documents, or that they should work hard to guess what the author meant,
>or that we should encourage or tolerate invalid documents. We should try
>still try to get rid of invalid documents, but taking things out on the
>users is the wrong way to do it.

"Postel's Law", generally quoted as "be liberal in what you accept and 
conservative in what you put out", was originally stated thus:


>   The implementation of a protocol must be robust.  Each implementation
>   must expect to interoperate with others created by different
>   individuals.  While the goal of this specification is to be explicit
>   about the protocol there is the possibility of differing
>   interpretations.  In general, an implementation should be conservative
>   in its sending behavior, and liberal in its receiving behavior.  That
>   is, it should be careful to send well-formed datagrams, but should
>   accept any datagram that it can interpret (e.g., not object to
>   technical errors where the meaning is still clear).

It was not meant as a universal law for all applications, it was a great 
design guideline for an Internet protocol. It was not phrased as a 
universal law, but as a guideline that is useful "in general" for protocols.

It's not a great policy in some environments. If you are a database, 
blindly shooting data that is clearly bad into the database will get you 
into trouble very quickly. If you are a web site that displays stock 
prices, and you get a data feed that says that the S&P is in negative 
digits, you probably do not want to pass that information on to the user, 
it is much better to raise an error.

It's not a bad policy for browsers. The web log entry seems to be thinking 
primarily about things like text oriented web pages, and seems to make the 
assumption that XML is primarily another web page format. If Aaron is 
trying to say that a web browser that is trying to display XML should try 
to recover from errors and display whatever it can, that makes sense. He 
could have said it more clearly.

Jonathan  


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.