OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] XML Sucks

[ Lists Home | Date Index | Thread Index ]

On Mon, May 05, 2003 at 11:56:43AM +0100, Sean McGrath wrote:
> Quote:
> "XML is useful in appropriate contexts, but it is being grossly abused in 
> most of the ways it is being used today."
> 
> Here is the most XML-ish part:
>         http://www.artima.com/intv/plain4.html
> 
> Full article starts here:
>         http://www.artima.com/intv/plain.html
> 
> My take? Some of its right and some of its wrong. There was a time when 
> most of it was wrong. Back in the early days of XML before we layered all 
> the crud on that allows people to - quite understandably - balk at the 
> sheer complexity and not-for-human-consumption of XML 2003.

Sounds like Dave and Andy are throwing out the baby with the bath water,
and you're somewhat happy to help them do it.

Truth is that designing a data format -- in XML or plaintext -- is
hard work, and most people do a very poor job of it.  (Raw) XML
simplifies many of these issues.  With XML,  all of a sudden people
can interchange data files without having to think about nasty
grammar issues.  Either an XML file you generate/receive is
syntactically correct, or it isn't.

There's a *huge* benefit there, as Tim Bray points out every month or so.
If I'm writing a program to parse your XML data, and my program barfs
due to a well-formedness error, I know you are the guilty party.  If
your data parses xmlwf, then I know the problem is with my buggy code.

If we take a step back and start to shun XML because it is so easy
to misuse, what's left?  Regular expressions and yacc grammars?
No thank you.  That's a return to the bad old days when I'm debugging
your data *and* my buggy program in order to use your data.  Worst
case, my program crashes inexplicably because your data deviates
from its published format or my expectations of your format.  And
there's no promise that my program won't silently fail!  How's that for
reuse?

XML on the whole has saved programmer-decades of effort in some
domains, while it has wasted programmer-decades of effort in others.
The Ant build file format is an example of something that shouldn't
have been an XML format because the benefit to the implementor is
massively outweighted by the wasted time of the user.  But what's
the solution?  Makefiles?  No thank you; Makefiles are a many
splendored family of stunningly similar formats that are all slightly
incompatible with each other.  (I've lost count of the times I tried to
make something on a BSD system and found it not work properly because
BSD is not GNUMake and vice versa.)


So while it's a wise suggestion to return to simple, text-based
formats, it sounds like Dave and Andy don't remember the downsides
to their proposal.  Sure there are benefits to using plaintext
instead of bastardizing XML into a form unfit for human use.  But
the nastiness and unreliability of plaintext parsing is one of the
factors that led to XML in the first place.

And that's a lesson that I dont' think many of us want to repeat...

Z.


  • References:
    • XML Sucks
      • From: Sean McGrath <sean.mcgrath@propylon.com>



 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS