From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a26758eec3c2e1ad X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-06-13 09:57:42 PST Message-ID: <3D08CD73.8060309@cogeco.ca> From: "Warren W. Gay VE3WWG" User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.4.1) Gecko/20020508 Netscape6/6.2.3 X-Accept-Language: en-us MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Use of XML for config files References: <3CFC5DB2.A21DCF61@cs.tu-berlin.de> <4519e058.0206041129.5b250124@posting.google.com> <4519e058.0206100702.5a4b431a@posting.google.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Date: Thu, 13 Jun 2002 12:50:59 -0400 NNTP-Posting-Host: 198.96.47.195 X-Complaints-To: abuse@sympatico.ca X-Trace: news20.bellglobal.com 1023987058 198.96.47.195 (Thu, 13 Jun 2002 12:50:58 EDT) NNTP-Posting-Date: Thu, 13 Jun 2002 12:50:58 EDT Organization: Bell Sympatico Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!sunqbc.risq.qc.ca!torn!webster!nf1.bellglobal.com!nf2.bellglobal.com!news20.bellglobal.com.POSTED!not-for-mail Xref: archiver1.google.com comp.lang.ada:25889 Date: 2002-06-13T12:50:59-04:00 List-Id: Stephen Leake wrote: > "Tarjei T. Jensen" writes: >>Stephen Leake wrote: >> >>>However, I think a sufficiently small subset of XML is ok. I'll be >>>posting a complete example Real Soon Now :). >> >>Aaarrrggggghhhhhhhh!!!!!!!!! >> >>When will people learn that config files should be readable and >>understandable. > > Yes, that is one of the requirements for Config_Files. > > You seem to be implying that XML is inherently _not_ readable, or > _not_ understandable. > > Many people here disagree. If your goal is to provide a configuration file that is as simple as a .ini file, then I think any subset of XML is a poor choice. Here's one reason why: It _does_ add complexity. As Ted mentioned in an earlier post, if you had to describe to a person who barely can handle an editor over the phone (the worst kind of support position), you would have to ask many questions about whether a tag was properly closed etc. You'd have to start by describing how tags open and close for starters.. and they probably wouldn't really get it anyway. Then going beyond that to nested tags - arg! I for one, would hate to be in that sort a support role. But even ignoring support roles, it is easier to describe an ini file change, than a XML change in a document. BUT, if your _goal_ is a hierarchical structure like the Windoze registry, then I think you should be prepared to accept binary and focus on it at the API and implementation level. The way to make it user configurable, is to provide a regedit type of tool that is general enough to handle most cases. Perhaps make it type extendable that is supported by dynamic shared libraries. Furthermore, it is then possible to layer some ACL type of security on your values. I personally would like to see this registry-like data in a postgres database, with a smooth API to access/create/modify values. The disadvantage of course, is that this would require that Postgres be running on all hosts where your application goes. There is a fellow that is attempting to put all Linux configuration values into a Postgres database. I think I saw this in a Linux publication last fall. This approach will then make it easier to configure all aspects of the system from a GUI. So many have already said here: your implementation will depend upon your design goals. Warren.