Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Help me explain the benefits of XML and other markup languages

I am trying to convince some senior people at my company of the advantages of transmitting data in a structured format between two of our systems.

Currently one system outputs flat text files and complicated parsers have to be written to extract the data on the other side. Every time the data is changed, the 'positions' have to be adjusted and it's a headache to maintain and test.

Both sides here have inbuilt facilities for creating and manipulating XML, so what I'm after is a persuasive article, document, blog post, etc introducing XML (or any other markup language really) as an alternative to flat text aimed at people who may not have worked with it before.

Many thanks

like image 414
Internet man Avatar asked Sep 07 '09 16:09

Internet man


2 Answers

Don't underestimate yourself, first. Passion will win them over. It's the most important ingredient in a fight like this. Besides, truth is on your side here. It is extensible markup language after all. Extensible is in the name!

Here are a couple of articles to help you ...

  • http://www.simonstl.com/articles/whyxml.htm
  • http://observationsonceremoved.blogspot.com/2009/05/why-xml-is-important.html
  • http://www.xml.com/pub/a/2004/10/27/extend.html
  • http://www.gerrymcgovern.com/nt/2000/nt_2000_11_06_xml_is_important.htm
like image 90
Rap Avatar answered Sep 23 '22 05:09

Rap


Don't know of any articles off-hand but a few advantages:

  • Wide variety of XML parsers already available for practically every language.
  • Structured data makes coding much easier - e.g. "select every <abc> tag and grab the value of attribute def" is easier to understand than "go to line n, grab characters 20-30".
  • Easy to edit by hand (e.g. changing one value) - syntax highlighting in text editors makes this even easier.
  • Variable-length values, so no need to rewrite parser when data changes.
  • Easy conversion to other formats like HTML and maybe Word/Excel/OpenOffice formats.
  • Data integrity via DTDs.
  • Data is portable to other systems and could be parsed by another language trivially. With a custom parser it means rewriting from scratch...

The only disadvantage that springs to mind is that the file size may be greater. With compression the difference is negligible and the size may not matter anyway.

like image 23
DisgruntledGoat Avatar answered Sep 24 '22 05:09

DisgruntledGoat