On Fri, 25 Jun 2010, Mr. Demeanour wrote: > I note the objections to XML as a configuration language. Generally > these seem to be concerned with the difficulty of reading and editing > XML "as she is wrote", i.e. a UTF-8 document full of <> crows-feet, with > tags, attributes, processing-instructions, namespace-declarations and > all that. > > I'm not sure if I'm being technically correct; but the essence of an XML > document is a DOM tree, not any specific rendition of that tree. Given > some restricted XML-based notation (such as the notation for an rsyslog > configuration, for example) there's no intrinsic reason why the XML > document shouldn't be 'flattened' for storage, and represented as > something like an INI file. For config data, I favour flatness. I don't > think it's at all a good idea to be able to express if/then/else > constructs in a config file; that belongs in the code. The configuration > should be a static thing. > > So if XML is convenient because the DOM structure is convenient (e.g. > allowing easy 'grafting' of document fragments), one could read data > from a flatfile representation into a DOM during config file parsing, > and modules could query the DOM to find out how they are configured. The > use of a DOM internally doesn't compel the use of standard textual XML > notation for the config file itself. > > Sorry (again), if I've missed the point.
this is getting confusing. XML was proposed because the custom config language that would need a parser written for it was starting to look very similar to XML, so someone suggested using a standard XML parser instead of coding up a custom one. David Lang _______________________________________________ rsyslog mailing list http://lists.adiscon.net/mailman/listinfo/rsyslog http://www.rsyslog.com

