]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
don't count workers in processes which aren't actively serving requests.
authorGreg Ames <gregames@apache.org>
Tue, 31 Jul 2001 06:22:32 +0000 (06:22 +0000)
committerGreg Ames <gregames@apache.org>
Tue, 31 Jul 2001 06:22:32 +0000 (06:22 +0000)
it is necessary to check for the generation as well as "quiescing", in the
case of a restart where no workers have seen the PoD yet.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89821 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
modules/generators/mod_status.c
server/mpm/threaded/threaded.c
server/mpm/worker/worker.c

diff --git a/CHANGES b/CHANGES
index 1b63ba0c79cea985f0007c33debc56ed118d21d4..d9d1fff246716263cc2fda99e43def7482a77c60 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,10 @@
 Changes with Apache 2.0.23-dev
+
+  *) More stall fixes for the threaded & worker mpm's.
+     Make mod_status output more accurate.  Don't
+     count workers in processes which aren't actively
+     serving requests. [Greg Ames]
+     
   *) Win32: Get SSI exec cgi tag working. [Bill Stoddard]
 
   *) Add a single listener/multiple worker MPM.  This MPM is
index 226b0662f2db61f6fcaa3bf1bfb326104c52c37d..b713ee3cb795dd123897b28a71c049a22f0db69d 100644 (file)
@@ -321,7 +321,9 @@ static int status_handler(request_rec *r)
            ps_record = ap_scoreboard_image->parent[i];
            res = ws_record.status;
            stat_buffer[indx] = status_flags[res];
-            if (!ps_record.quiescing && ps_record.pid) {
+            if (!ps_record.quiescing && 
+                    ps_record.generation == ap_my_generation &&
+                    ps_record.pid) {
                if (res == SERVER_READY)
                    ready++;
                else if (res != SERVER_DEAD && res != SERVER_IDLE_KILL)
index 527df540907bf31b08ff1daf03ac2e5c59316f58..8cf6db30c68b119c87344610da29a4b735e31443 100644 (file)
@@ -1010,6 +1010,7 @@ static void perform_idle_server_maintenance(void)
             */
            if (status <= SERVER_READY && status != SERVER_DEAD &&
                     !ps->quiescing &&
+                    ps->generation == ap_my_generation &&
                  /* XXX the following shouldn't be necessary if we clean up 
                   *     properly after seg faults, but we're not yet    GLA 
                   */     
index 8e6f1aaaf39d5f0619bd6b82888898d303105f7a..88063cdbbd0432a7295e3a68f2bdf22160ddf3ba 100644 (file)
@@ -1058,6 +1058,7 @@ static void perform_idle_server_maintenance(void)
             */
            if (status <= SERVER_READY && status != SERVER_DEAD &&
                     !ps->quiescing &&
+                    ps->generation == ap_my_generation &&
                  /* XXX the following shouldn't be necessary if we clean up 
                   *     properly after seg faults, but we're not yet    GLA 
                   */