httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <traw...@attglobal.net>
Subject Re: cvs commit: httpd-2.0/server/mpm/worker worker.c
Date Wed, 20 Mar 2002 13:00:15 GMT
wrowe@apache.org writes:

> wrowe       02/03/19 21:58:21
> 
>   Modified:    server/mpm/beos beos.c
>                server/mpm/netware mpm_netware.c
>                server/mpm/perchild perchild.c
>                server/mpm/prefork prefork.c
>                server/mpm/winnt mpm_winnt.c
>                server/mpm/worker worker.c
>   Log:
>     The pre_mpm hook creates server-lifetime objects (or at least, for the
>     generations across graceful restarts.)  They should use the process pool.

The pre_mpm hook doesn't seem generically useful.  It seems to be tied
to our current idea of how the scoreboard should be managed.

>   Index: beos.c
>   ===================================================================
>   RCS file: /home/cvs/httpd-2.0/server/mpm/beos/beos.c,v
>   retrieving revision 1.88
>   retrieving revision 1.89
>   diff -u -r1.88 -r1.89
>   --- beos.c	15 Mar 2002 00:50:31 -0000	1.88
>   +++ beos.c	20 Mar 2002 05:58:20 -0000	1.89
>   @@ -839,7 +839,7 @@
>        
>        if (!is_graceful) {
>            /* setup the scoreboard shared memory */
>   -        if (ap_run_pre_mpm(pconf, SB_SHARED) != OK) {
>   +        if (ap_run_pre_mpm(s->process->pool, SB_SHARED) != OK) {
>                return 1;
>            }

Now the scoreboard lives forever and it is safe to call
ap_run_pre_mpm() at any restart.  One piece I think you have missed is
proper initialization of the scoreboard after a non-graceful restart.

For a graceful restart we don't want cleared scoreboard values (and
we don't).

For a non-graceful restart we do want a fresh (or at least cleared)
scoreboard (and we don't get that any more).

Isn't non-graceful restart now broken?  (There is plenty of
opportunity for me to be confused here.)

Can you remind me what was broken before this commit?

-- 
Jeff Trawick | trawick@attglobal.net
Born in Roswell... married an alien...

Mime
View raw message