tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefano Mazzocchi <stef...@apache.org>
Subject Re: XML configuration revisited
Date Wed, 20 Oct 1999 19:54:48 GMT
Ben Laurie wrote:
> 
> Dirk-Willem van Gulik wrote:
> >
> > On Mon, 11 Oct 1999, Ben Laurie wrote:
> >
> > ...
> > > > Our idea at this point is to build a simple DTD that incorporates both
> > > > the Apache config details and the future web.xml DTD. For the time
> > > > being, we will edit the XML config by hand and write a simple parser to
> > > > spit out httpd.conf and jserv.conf/jserv.properties/servlets.properties.
> > > > We would like some feedback and see if anyone else is already working
on
> > > > this, possibly as part of Jakarta.
> > >
> > > It has been discussed on the Tomcat mailing list, but so far without
> > > much in the way of conclusions.
> > >
> > > The major issue I see is that Apache's configuration is extensible, but
> > > DTDs are not (at least, as far as I understand them). So, some kind of
> > > XDTD (to coin an acronym) is needed. I believe such things do exist, but
> > > I don't know much about them. However, the fact that they are plural
> > > worries me :-)
> >
> > Well, actually by introducing the DTD you kind of shoot yourself in the
> > foot. If you for a moment assumens that your XML is 'correct' and contains
> > no semantic errors (well formness can be cheched on the fly) then you
> > can dynamically build the correct tree in memory flexible enough and
> > without the need for a DTD.
> >
> > This sort of assumes you have tools to do this. Obviously those tools
> > would like to have DTD's or some XSL or XML like data semantics construct
> > to drive the tool itself; so that you can add, say the configuration of
> > module X, by simply splicing in some DTD like info.. causing the tool to
> > add the right widows, fields and widgets.
> >
> > But to return, IMHO adding, or even mandating a DTD from our side smells
> > a lot like shooting ourselfes in the foot.
> 
> At the risk of repeating myself... I don't think we need DTDs but we
> need some way to describe the format of the XML.

Totally, this is _exactly_ what Eric (eric@w3c.org), Daniel Lopez
(comanche author), Pierpaolo Fumagalli and I have been talking about
since ApacheCon98!!!

We call that "meta-configurations", which wrap around configurations and
allow project-independent tools to _know_ what to do with the project
configurations based on that information.

XML validation is then needed only for the meta-configuration file which
is written by the project authors and should be read-only for users.

IMO, configuration validation is pointless since your software has to
validate it anyway it its own personal manner and no DTD or XSchema can
cover all logic faults.

My 0.02 Euros.

-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<stefano@apache.org>                             Friedrich Nietzsche
---------------------------------------------------------------------



Mime
View raw message