httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Greg Stein <>
Subject Re: [PATCH] Config modules step 1
Date Wed, 12 Apr 2000 20:13:15 GMT
On Wed, 12 Apr 2000 wrote:
> > A more intuitive tree would look like:
> > 
> >   Top-level directive
> >   Top-level directive
> >   <Directory /foo>
> >       Dir-level directive
> >       Dir-level directive
> >   Top-level directive
> I actually agreed with you when I started, and about half way through, I
> decided I liked this better.  The tree itself denotes the containers,
> instead of the directives.  This puts everything related to a directory
> container on the same level of the tree.  I'm not married to either
> approach, so if you feel strongly about this let me know.

Yes, I do feel strongly about it :-)

Imagine the case where you're trying to find "/foo". You scan the
top-level quickly for it. There is no need to bounce down into child nodes
looking for the thing.

The top-level <Directory> is a directive that applies to the top-level, so
it should be a sibling of the other top-level directives. The config for
that directory is enclosed inside.

I could probably find a couple other reasons, but I'll stop now :-)

> One of the
> other things I like about the current approach is that we don't need to
> keep an extra pointer to the current pointer.  Depending on how complex
> your config is, that could be a lot of extra pointers that are really not
> necessary.

The current_parent is a static, just like current. Sorry that I didn't
make that clear. As a result, you don't end up with pointer bloat :-)

> Can I assume that once all of the above issues are fixed, you are giving a
> +1 to this?

If the tree structure is changed, then I'm +1! Good stuff! :-)


Greg Stein,

View raw message