comp.lang.ada
 help / color / mirror / Atom feed
From: Darren New <dnew@san.rr.com>
Subject: Re: Use of XML for config files
Date: Wed, 12 Jun 2002 15:33:48 GMT
Date: 2002-06-12T15:33:48+00:00	[thread overview]
Message-ID: <3D0769F7.68F5BD9C@san.rr.com> (raw)
In-Reply-To: ae7b34$ms9$1@a1-hrz.uni-duisburg.de

Georg Bauhaus wrote:
> 
> Ted Dennison <dennison@telepath.com> wrote:
> : What's wrong is:
> :
> : 1) It could be *far* smaller than that, if we were parsing a simpler
> : syntax.
> 
> far by what amount?
> <item key="the_key">value string of some average length</item>
> the_key:=value string of some average length
> 
> 2/3.

Ted was talking about the code being smaller, not the config file.

It is far easier to split a string at an = than it is to parse even
restricted XML.

> You mention real time systems, but I wonder whether a configuration
> for an AWS application will get anything but messy if it has to
> be configured with key value pairs only.

Yes, but it will be simple, and relatively easy to edit by hand, which was
the point. Every suggestion at something more complex than simple
string=string runs into the problem of editing it by hand.

> Ada equivalent: put everything
> in one big package.

Well, that's why the config file has sections and nested heirarchical names
and multiple config files per program.
 
> I don't understand this verbosity and design aversion in an Ada context :-)

The people editing the config file might not be Ada programmers.
 
> : I will cost us, in that it will make the file much harder for humans
> : to read.
> 
> Depends. (On the design of the (implicit or explicit) DTD.

No, it doesn't. XML requires balanced start and end tags, it requires quotes
in attributes, it requires that less-than and ampersand in PCDATA be
escaped, none of which is true for INI formats and all of which is true
regardless of the DTD.

> : I'm particuarly thinking of the site maintanence engineers
> 
> who could use _any_ XML enabled editing tool to write valid
> configuration files (where valid refers to XML validation).

Errr... as opposed to using 'cat' to edit INI files?
 
> : as its easy to forget an end tag or
> : transpose a letter somewhere.
> 
> the idea behind XML is that you don't have to write tags yourself.
> That would be the province of the XML application (e.g. editor) or

So why not allow binary in the files, if you need to use a special editor to
edit them? I think we're starting to go in circles at this point.

I think the question you have to answer clearly, if you're advocating XML,
is what benefit does it offer this project above and beyond the capabilities
that an INI-format file would offer?

> Should the decision between very simple Key(i) = value(i)
> and a grammar driven externally checked configuration be frozen
> in the API?

I think if you're looking for a simple config file API, then yes. If you're
looking for full-blown XML with namespaces and cross references and all,
you're looking at something best done with a full-blown XML parser, at which
point who needs a config file API anyway?

-- 
Darren New 
San Diego, CA, USA (PST). Cryptokeys on demand.
** http://home.san.rr.com/dnew/DNResume.html **
** http://images.fbrtech.com/dnew/ **

     My brain needs a "back" button so I can
         remember where I left my coffee mug.



  reply	other threads:[~2002-06-12 15:33 UTC|newest]

Thread overview: 83+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-03 11:48 Use of XML for config files Mike and Lynn Card
2002-06-03 17:42 ` Pascal Obry
2002-06-04  6:26 ` Volkert Barr
2002-06-04 12:47   ` SteveD
2002-06-04 13:51     ` Volkert Barr
2002-06-04 19:29   ` Ted Dennison
2002-06-05  7:18     ` Volkert Barr
2002-06-05 10:24       ` Georg Bauhaus
2002-06-05 11:35         ` Preben Randhol
2002-06-05 14:52           ` Georg Bauhaus
2002-06-05 15:22             ` Preben Randhol
2002-06-05 19:11             ` Darren New
2002-06-06 13:38               ` Georg Bauhaus
2002-06-06 15:06                 ` Darren New
2002-06-07 11:28                   ` Georg Bauhaus
2002-06-07 17:10                     ` Darren New
2002-06-06  6:48           ` Volkert Barr
2002-06-06 13:27             ` Georg Bauhaus
2002-06-05 14:41       ` Robert C. Leif
2002-06-09 22:00     ` Stephen Leake
2002-06-10 15:03       ` Ted Dennison
2002-06-10 18:12         ` Stephen Leake
2002-06-12 11:25         ` Georg Bauhaus
2002-06-12 15:33           ` Darren New [this message]
2002-06-12 17:53             ` Stephen Leake
2002-06-13 14:18               ` Ted Dennison
2002-06-13 16:36                 ` Stephen Leake
2002-06-14  3:27                   ` Ted Dennison
2002-06-14 15:54                     ` Stephen Leake
2002-06-12 19:18             ` Georg Bauhaus
2002-06-13 13:53             ` Ted Dennison
2002-06-13 15:26               ` Georg Bauhaus
2002-06-13 16:39               ` Darren New
2002-06-13 17:06                 ` Georg Bauhaus
2002-06-13 17:43                   ` Darren New
2002-06-14 15:56                     ` Georg Bauhaus
2002-06-13 17:54                 ` Georg Bauhaus
2002-06-13 18:31                   ` Darren New
2002-06-14 16:04                     ` Stephen Leake
2002-06-14 16:48                       ` Darren New
2002-06-14 17:03                     ` Georg Bauhaus
2002-06-14 17:22                       ` Darren New
2002-06-18 15:20                         ` Georg Bauhaus
2002-06-18 15:37                           ` Darren New
2002-06-18 18:20                             ` Georg Bauhaus
2002-06-18 19:11                               ` Stephen Leake
2002-06-18 21:47                               ` Darren New
2002-06-19 11:31                                 ` Georg Bauhaus
2002-06-19 15:13                                   ` Stephen Leake
2002-06-19 21:14                                     ` Georg Bauhaus
2002-06-20 14:38                                       ` Stephen Leake
2002-06-20 16:02                                         ` Georg Bauhaus
2002-06-20 20:37                                           ` Stephen Leake
2002-06-21 16:24                                             ` Ted Dennison
2002-06-24 14:11                                               ` Stephen Leake
2002-06-19 16:43                                   ` Darren New
2002-06-19 20:33                                     ` Georg Bauhaus
2002-06-12 17:48           ` Stephen Leake
2002-06-13  7:42             ` Tarjei T. Jensen
2002-06-13 13:53               ` Georg Bauhaus
2002-06-13 14:10               ` Stephen Leake
2002-06-13 16:50                 ` Warren W. Gay VE3WWG
2002-06-13 17:31                   ` Tarjei Tj�stheim Jensen
2002-06-14 16:11                   ` Stephen Leake
2002-06-13 17:28                 ` Tarjei Tj�stheim Jensen
2002-06-19  9:48                   ` Preben Randhol
2002-06-10 14:45     ` Georg Bauhaus
2002-06-09 21:52   ` Stephen Leake
2002-06-10  0:02     ` Preben Randhol
2002-06-10 12:42       ` Stephen Leake
2002-06-10 16:21         ` Pascal Obry
2002-06-12 11:29           ` Georg Bauhaus
  -- strict thread matches above, loose matches on Subject: below --
2002-06-05  7:33 Grein, Christoph
2002-06-05  7:59 ` Volkert Barr
2002-06-05  8:25 Grein, Christoph
2002-06-05  8:39 ` Volkert Barr
2002-06-05  9:31 ` Manuel Collado
2002-06-05 10:01   ` Volkert Barr
2002-06-05 10:02 Grein, Christoph
2002-06-09 22:13 ` Stephen Leake
2002-06-10  1:42   ` Darren New
2002-06-10 12:46     ` Stephen Leake
2002-06-10 15:52       ` Darren New
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox