mpm_worker: Fix cases where the spawn rate wasn't reduced after
child process resource shortages.
(Note: mpm_event is omitted from this backport proposal because of
missing prerequisite fixes. Even mpm_worker has a tiny issue,
described in comments in the code.)
Submitted by: trawick
Reviewed by: rjung, rpluem
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@
1373342 13f79535-47bb-0310-9956-
ffa450edef68
envvars: Fix insecure handling of LD_LIBRARY_PATH that could lead to the
current working directory to be searched for DSOs. [Stefan Fritsch]
+ *) mpm_worker: Fix cases where the spawn rate wasn't reduced after child
+ process resource shortages. [Jeff Trawick]
+
*) mpm_prefork: Reduce spawn rate after a child process exits due to
unexpected poll or accept failure. [Jeff Trawick]
2.2.x patch: http://people.apache.org/~jim/patches/mod_proxy_ajp-erroroverride.patch
+1: igalic, jim, rpluem
- * mpm_worker: Fix cases where the spawn rate wasn't reduced after
- child process resource shortages.
- (Note: mpm_event is omitted from this backport proposal because of
- missing prerequisite fixes. Even mpm_worker has a tiny issue,
- described in the patch.)
- trunk patch: http://svn.apache.org/viewvc?view=rev&rev=1363440
- 2.2.x patch: http://people.apache.org/~trawick/r1363440-worker-only-2.2.x.txt
- +1: trawick, rjung, rpluem
-
* mod_proxy_balancer: Restore balancing after a failed worker has
recovered when using lbmethod_bybusyness. PR 48735.
trunk patch: http://svn.apache.org/viewvc?view=revision&revision=1366344
}
else if (ap_unregister_extra_mpm_process(pid.pid) == 1) {
/* handled */
+ if (processed_status == APEXIT_CHILDSICK) {
+ /* resource shortage, minimize the fork rate */
+ /* 2.2.x note: Unlike 2.4+, there's no way to verify that
+ * this child was part of the current generation, so we
+ * can't leave the spawn rate alone for sick children of
+ * previous generations.
+ */
+ idle_spawn_rate = 1;
+ }
#if APR_HAS_OTHER_CHILD
}
else if (apr_proc_other_child_alert(&pid, APR_OC_REASON_DEATH,