httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mladen Turk <>
Subject LoadModule questions on WIN32
Date Mon, 05 Sep 2005 07:54:51 GMT

Since we have a problem with recent patched from Jim for
loadbalancer, that basically core dumps WIN32 build, and
I suppose other platforms are working OK, I've done some
debugging adding traces to the various stages in module
loading and initialization, so I have a question if this
is correct behavior on all platforms.

1. LoadModule order in conf file defined the module
    loading order.
    That is correctly handled.

2. First thing called is register_hooks table.
    Suppose that is correct too.

Now, I would expect that the third hook called is 'pre_config',
but here is what happens for:

proxy_module --> [P]
proxy_balancer_module --> [B]

1. [P] register_hooks
2. [P] create_server_config
3. [P] create_dir_config
4. [B] register_hooks
5. [P] pre_config
6. [B] pre_config

So, both create server config and create dir config hooks are
called before the balancer module is loaded, and thus the function for
obtaining lbmethods is NULL, that later makes core dump on
the first request.

Also, I always thought that pre_config hook should precede any other
config hook.

If the upper scenario is correct, the only way to resolve the current
core dump is to revert the patch Jim made, because the current code
tries to load the function from the module that is not loaded jet.

Other option would be to use the APR optional functions, obtained
in the pre_config, but then again the create_server_config would
fail, because it is called before pre_config.


View raw message