You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ji...@apache.org on 2010/02/15 20:52:01 UTC
svn commit: r910320 - in /httpd/httpd/branches/2.2.x: CHANGES STATUS
server/mpm/worker/worker.c
Author: jim
Date: Mon Feb 15 19:52:00 2010
New Revision: 910320
URL: http://svn.apache.org/viewvc?rev=910320&view=rev
Log:
*) worker: Don't report server has reached MaxClients until it has.
Add message when server gets within MinSpareThreads of MaxClients.
PR 46996. [Dan Poirier]
Modified:
httpd/httpd/branches/2.2.x/CHANGES
httpd/httpd/branches/2.2.x/STATUS
httpd/httpd/branches/2.2.x/server/mpm/worker/worker.c
Modified: httpd/httpd/branches/2.2.x/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/CHANGES?rev=910320&r1=910319&r2=910320&view=diff
==============================================================================
--- httpd/httpd/branches/2.2.x/CHANGES [utf-8] (original)
+++ httpd/httpd/branches/2.2.x/CHANGES [utf-8] Mon Feb 15 19:52:00 2010
@@ -9,6 +9,10 @@
access control is still vulnerable, unless using OpenSSL >= 0.9.8l.
[Joe Orton, Ruediger Pluem, Hartmut Keil <Hartmut.Keil adnovum.ch>]
+ *) worker: Don't report server has reached MaxClients until it has.
+ Add message when server gets within MinSpareThreads of MaxClients.
+ PR 46996. [Dan Poirier]
+
*) mod_ssl: Reintroduce SSL_CLIENT_S_DN, SSL_CLIENT_I_DN, SSL_SERVER_S_DN,
SSL_SERVER_I_DN back to the environment variables to be set by mod_ssl.
[Peter Sylvester <peter.sylvester edelweb.fr>]
Modified: httpd/httpd/branches/2.2.x/STATUS
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/STATUS?rev=910320&r1=910319&r2=910320&view=diff
==============================================================================
--- httpd/httpd/branches/2.2.x/STATUS (original)
+++ httpd/httpd/branches/2.2.x/STATUS Mon Feb 15 19:52:00 2010
@@ -87,12 +87,6 @@
PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
[ start all new proposals below, under PATCHES PROPOSED. ]
- * worker: Don't log MaxClients until we actually hit it. Warn when within
- MinSpareThreads of MaxClients.
- Trunk patch: http://svn.apache.org/viewvc?rev=906535&view=rev
- 2.2.x patch: http://people.apache.org/~poirier/maxclients-2.2.patch
- +1: poirier, minfrin, jim
-
* mod_proxy: Allow https to a remote forward proxy by issuing an HTTP
CONNECT request. This adds a CONNECT client (sending a connect request).
It is not the same as mod_proxy_connect, which is a CONNECT server
Modified: httpd/httpd/branches/2.2.x/server/mpm/worker/worker.c
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/server/mpm/worker/worker.c?rev=910320&r1=910319&r2=910320&view=diff
==============================================================================
--- httpd/httpd/branches/2.2.x/server/mpm/worker/worker.c (original)
+++ httpd/httpd/branches/2.2.x/server/mpm/worker/worker.c Mon Feb 15 19:52:00 2010
@@ -1513,15 +1513,32 @@
else if (idle_thread_count < min_spare_threads) {
/* terminate the free list */
if (free_length == 0) {
- /* only report this condition once */
- static int reported = 0;
-
- if (!reported) {
- ap_log_error(APLOG_MARK, APLOG_ERR, 0,
- ap_server_conf,
- "server reached MaxClients setting, consider"
- " raising the MaxClients setting");
- reported = 1;
+ /* No room for more children, might warn about configuration */
+ if (active_thread_count >= ap_daemons_limit * ap_threads_per_child) {
+ /* no threads are "inactive" - starting, stopping, etc. - which would confuse matters */
+ /* Are all threads in use? Then we're really at MaxClients */
+ if (0 == idle_thread_count) {
+ /* only report this condition once */
+ static int reported = 0;
+
+ if (!reported) {
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0,
+ ap_server_conf,
+ "server reached MaxClients setting, consider"
+ " raising the MaxClients setting");
+ reported = 1;
+ }
+ } else {
+ static int reported = 0;
+
+ if (!reported) {
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0,
+ ap_server_conf,
+ "server is within MinSpareThreads of MaxClients, consider"
+ " raising the MaxClients setting");
+ reported = 1;
+ }
+ }
}
idle_spawn_rate = 1;
}