In lieu of a quick answer, I find:

 http://www.fmc-modeling.org/projects/apache/html/Apache_Modeling_Project.html

to be a very good read and source of information about Apache internals.

There is a section on configuration in there and I vaguely remember it
describing somewhere where the multiple server/dir configs come from
plus why your command processors get called multiple times.

Bit too busy right now to hunt down the actual section for you.

Graham

On 09/05/07, Sam Carleton <[EMAIL PROTECTED]> wrote:
I simply don't understand how module configuration is suppose to work.
 I am handling the server and dir config create and merge.  For some
reason, unknown to me, the server creation function gets called twice
in my development environment where I am passing httpd.exe the -X.  Of
course this means that the function to handle the command gets called
twice, too.  It might be nice to understand why it gets called twice,
but that isn't the problem.  The dir configuration creation gets
called twice, too but also seems to work fine.

Inside my access hook when I make this call:

ap_get_module_config(r->server->module_config, &my_module)

I get an empty configuration block, but when I change the first
parameter to "r->per_dir_config", I get the server configuration
block.  What?  Why doesn't r->server->module_config return me the
server configuration block and r->per_dir_config either return nothing
or the applicable dir configuration block.

Am I doing something wrong?  If not, is this documented somewhere?

Sam

Reply via email to