You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Paul Querna <ch...@force-elite.com> on 2005/12/03 23:40:19 UTC
Making MPMs DSOs
I am trying to sketch out the issues with allowing MPMs to be loaded as
DSOs, specified from the conf file.
1) AP_MPM_WANT_*. These defines come from the mpm.h, and are used all
over the core. A significant number of them are for adding
configuration directives. The rest are generally changing the behavior
of the mpm_common stuff.
Here is the full list from trunk:
AP_MPM_WANT_FATAL_SIGNAL_HANDLER
AP_MPM_WANT_PROCESS_CHILD_STATUS
AP_MPM_WANT_RECLAIM_CHILD_PROCESSES
AP_MPM_WANT_SET_ACCEPT_LOCK_MECH
AP_MPM_WANT_SET_COREDUMPDIR
AP_MPM_WANT_SET_GRACEFUL_SHUTDOWN
AP_MPM_WANT_SET_LOCKFILE
AP_MPM_WANT_SET_MAX_MEM_FREE
AP_MPM_WANT_SET_MAX_REQUESTS
AP_MPM_WANT_SET_PIDFILE
AP_MPM_WANT_SET_SCOREBOARD
AP_MPM_WANT_SET_STACKSIZE
AP_MPM_WANT_SIGNAL_SERVER
AP_MPM_WANT_WAIT_OR_TIMEOUT
2) Build system issues. Need to make the MPMs build as .so
3) The scoreboard. Each group of MPMs handles it differently. The
Event MPM is also re-shaping what a 'connection' means, and this will
likely lead to more scoreboard changes. We need a better common API to
reading and writing to the scoreboard. It would also be nice for other
modules, like mod_ldap and mod_dbd, which might want to keep global
state/stats around.
4) mpm_common.c uses ap_server_conf, which is a global variable in each
MPM. It needs to be moved to be completely inside mpm_common.c.
5) Where to put the DSO Loading code? I sketched out putting it into
mod_so.. I am not sure if it would be easier to just stick it into the core.
Those are the the big ones that I see. I will try to tackle them one at
a time, and when its all done, I think it will work.
-Paul