From: Jeff Trawick Date: Mon, 19 Nov 2001 18:07:28 +0000 (+0000) Subject: Get rid of threaded MPM. This commit has the actual code changes. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2f723346fd2adff1cdf611787f996d6f553e2701;p=apache Get rid of threaded MPM. This commit has the actual code changes. The deletes come next. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@92036 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index 026557cceb..20435e5a64 100644 --- a/CHANGES +++ b/CHANGES @@ -1,5 +1,8 @@ Changes with Apache 2.0.29-dev + *) The threaded MPM for Unix has been removed. Use the worker + MPM instead. [various] + *) APR-ize the resolver logic in mod_unique_id. This fixes a bug in logging the error from a failed DNS lookup. [Jeff Trawick] diff --git a/STATUS b/STATUS index a0860fe01d..cd19693148 100644 --- a/STATUS +++ b/STATUS @@ -1,5 +1,5 @@ APACHE 2.0 STATUS: -*-text-*- -Last modified at [$Date: 2001/11/19 13:48:57 $] +Last modified at [$Date: 2001/11/19 18:07:27 $] Release: @@ -191,7 +191,7 @@ RELEASE NON-SHOWSTOPPERS BUT WOULD BE REAL NICE TO WRAP THESE UP: decoupled now, but isn't really sure. * Performance: Get the SINGLE_LISTEN_UNSERIALIZED_ACCEPT - optimization working in threaded. prefork's new design for how + optimization working in worker. prefork's new design for how to notice data on the pod should be sufficient. * Performance & Debug: Eliminate most (and perhaps all) of the @@ -251,7 +251,6 @@ RELEASE NON-SHOWSTOPPERS BUT WOULD BE REAL NICE TO WRAP THESE UP: prefer htpasswd: prefer seperate: OtherBill - * use apu_dbm in mod_auth_dbm Status: Greg +1 (low-priority volunteer) Justin says: "Seems like this is already there, so should we just @@ -315,16 +314,13 @@ RELEASE NON-SHOWSTOPPERS BUT WOULD BE REAL NICE TO WRAP THESE UP: search for libssl and libcrypto and properly add them to mod_ssl's link flags. - * Remove the threaded MPM. - +1: Ryan, Justin, Jeff, Ian, Aaron, Cliff, Greg Ames - +0: - -1: - * Make the worker MPM the default MPM for threaded Unix boxes. +1: Justin, Jeff, Ian -0: Aaron (premature decision, needs more discussion) -0: Cliff (I think the default config should be the safest possible) + * The worker MPM needs some doc. + PRs that have been suspended forever waiting for someone to put them into 'the next release': diff --git a/docs/conf/highperformance-std.conf b/docs/conf/highperformance-std.conf index b0060882a8..2d35616516 100755 --- a/docs/conf/highperformance-std.conf +++ b/docs/conf/highperformance-std.conf @@ -26,14 +26,6 @@ MinSpareServers 5 MaxSpareServers 10 - -MaxClients 8 -StartServers 3 -MinSpareThreads 5 -MaxSpareThreads 10 -ThreadsPerChild 25 - - MaxClients 8 StartServers 3 diff --git a/docs/conf/httpd-std.conf b/docs/conf/httpd-std.conf index 8fe1bac486..698a197ada 100644 --- a/docs/conf/httpd-std.conf +++ b/docs/conf/httpd-std.conf @@ -117,22 +117,6 @@ MaxClients 150 MaxRequestsPerChild 0 -# threaded MPM -# StartServers: initial number of server processes to start -# MaxClients: maximum number of server processes allowed to start -# MinSpareThreads: minimum number of worker threads which are kept spare -# MaxSpareThreads: maximum number of worker threads which are kept spare -# ThreadsPerChild: constant number of worker threads in each server process -# MaxRequestsPerChild: maximum number of requests a server process serves - -StartServers 3 -MaxClients 150 -MinSpareThreads 25 -MaxSpareThreads 75 -ThreadsPerChild 25 -MaxRequestsPerChild 0 - - # worker MPM # StartServers: initial number of server processes to start # MaxClients: maximum number of simultaneous client connections diff --git a/docs/manual/mod/index-bytype.html b/docs/manual/mod/index-bytype.html index d6cd33a7cd..42a8f5314e 100644 --- a/docs/manual/mod/index-bytype.html +++ b/docs/manual/mod/index-bytype.html @@ -28,7 +28,7 @@
Core Apache features.
-
threaded
+
worker
Multi-Processing Module with Threading via Pthreads; Variable number of processes, constant number of diff --git a/docs/manual/mod/index.html b/docs/manual/mod/index.html index 40a1522fbf..895560fe19 100644 --- a/docs/manual/mod/index.html +++ b/docs/manual/mod/index.html @@ -28,7 +28,7 @@
Core Apache features.
-
threaded
+
worker
Multi-Processing Module with Threading via Pthreads; Variable number of processes, constant number of diff --git a/docs/manual/mod/mpm_common.html b/docs/manual/mod/mpm_common.html index 11c2c3d6a4..6f53267250 100644 --- a/docs/manual/mod/mpm_common.html +++ b/docs/manual/mod/mpm_common.html @@ -99,7 +99,7 @@ Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork, mpm_winnt

This controls the directory to which Apache attempts to @@ -126,7 +126,7 @@ Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork

The Group directive sets the group under which the server will answer requests. In order to use this directive, the @@ -173,7 +173,7 @@ Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork, mpm_winnt

The PidFile directive sets the file to which the server @@ -203,7 +203,7 @@ Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork, mpm_winnt

The Listen directive instructs Apache to listen to only @@ -260,7 +260,7 @@ Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork, mpm_winnt

The maximum length of the queue of pending connections. @@ -290,7 +290,7 @@ Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork

The LockFile directive sets the path to the lockfile used @@ -326,7 +326,7 @@ Status: MPM
Module: threaded, prefork

+ rel="Help">Module: worker, prefork

The MaxClients directive sets the limit on the number of child processes that will be created to serve requests. When @@ -363,7 +363,7 @@ Status: MPM
Module: threaded, prefork, + rel="Help">Module: worker, prefork, perchild, mpm_winnt

The MaxRequestsPerChild directive sets the limit on the @@ -397,21 +397,21 @@ number
Default: MaxSpareThreads - 10 (Perchild) or 500 (threaded)
+ 10 (Perchild) or 500 (worker)
Context: server config
Status: core
Module: threaded, perchild

+ rel="Help">Module: worker, perchild

Maximum number of idle threads. Different MPMs deal with - this directive differently. Perchild monitor the number of idle + this directive differently. Perchild monitors the number of idle threads on a per-child basis. If there are too many idle threads in that child, the server will begin to kill threads within that child.

-

threaded deals with idle threads on a server-wide basis. If +

worker deals with idle threads on a server-wide basis. If there are too many idle threads in the server then child processes are killed until the number of idle threads is less than this number.

@@ -434,7 +434,7 @@ Status: core
Module: threaded, perchild

+ rel="Help">Module: worker, perchild

Maximum number of threads per child. For MPMs with a variable number of threads per child, this directive sets the @@ -453,21 +453,21 @@ number
Default: MaxSpareThreads - 5 (Perchild) or 250 (threaded)
+ 5 (Perchild) or 250 (worker)
Context: server config
Status: core
Module: threaded, perchild

+ rel="Help">Module: worker, perchild

Minimum number of idle threads to handle request spikes. Different MPMs deal with this directive differently. Perchild - monitor the number of idle threads on a per-child basis. If + monitors the number of idle threads on a per-child basis. If there aren't enough idle threads in that child, the server will begin to create new threads within that child.

-

threaded deals with idle threads on a server-wide basis. If +

worker deals with idle threads on a server-wide basis. If there aren't enough idle threads in the server then child processes are created until the number of idle threads is greater than number.

@@ -513,7 +513,7 @@ rel="Help">Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork

The ScoreBoardFile directive is required on some @@ -546,7 +546,7 @@ Status: MPM
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork, mpm_winnt

The server will set the TCP buffer size to the number of bytes specified. Very useful to increase past standard OS defaults on @@ -569,7 +569,7 @@ Status: MPM
Module: threaded, prefork

+ rel="Help">Module: worker, prefork

The StartServers directive sets the number of child server processes created on startup. As the number of processes is @@ -616,14 +616,14 @@ Status: MPM
Module: threaded, mpm_winnt

+ rel="Help">Module: worker, mpm_winnt

This directive sets the number of threads created by each child process. The child creates these threads at startup and never creates more. if using an MPM like mpmt_winnt, where there is only one child process, this number should be high enough to handle the entire load of the server. If using an MPM - like threaded, where there are multiple child processes, the + like worker, where there are multiple child processes, the total number of threads should be high enough to handle the common load on the server.


@@ -643,7 +643,7 @@ Status: core
Module: threaded, perchild, + rel="Help">Module: worker, perchild, prefork

The User directive sets the userid as which the server will answer requests. In order to use this directive, the standalone diff --git a/docs/manual/mpm.html b/docs/manual/mpm.html index 93d0459665..db67792034 100644 --- a/docs/manual/mpm.html +++ b/docs/manual/mpm.html @@ -47,7 +47,7 @@
  • The server can be better customized for the needs of the particular site. For example, sites that need a great deal of scalability can choose to use a threaded MPM like threaded, while sites requiring + href="mod/worker.html">worker, while sites requiring stability or compatibility with older software can use a preforking MPM. In addition, special features like serving different hosts under different diff --git a/docs/manual/mpm.html.en b/docs/manual/mpm.html.en index 93d0459665..db67792034 100644 --- a/docs/manual/mpm.html.en +++ b/docs/manual/mpm.html.en @@ -47,7 +47,7 @@
  • The server can be better customized for the needs of the particular site. For example, sites that need a great deal of scalability can choose to use a threaded MPM like threaded, while sites requiring + href="mod/worker.html">worker, while sites requiring stability or compatibility with older software can use a preforking MPM. In addition, special features like serving different hosts under different diff --git a/modules/generators/config5.m4 b/modules/generators/config5.m4 index a4b37cea50..7113018226 100644 --- a/modules/generators/config5.m4 +++ b/modules/generators/config5.m4 @@ -13,7 +13,7 @@ APACHE_MODULE(suexec, set uid and gid for spawned processes, , , no, [ APR_ADDTO(LT_LDFLAGS,-export-dynamic) -if test "$apache_cv_mpm" = "worker" -o "$apache_cv_mpm" = "threaded" -o "$apache_cv_mpm" = "perchild"; then +if test "$apache_cv_mpm" = "worker" -o "$apache_cv_mpm" = "perchild"; then # if we are using a threaded MPM, we will get better performance with # mod_cgid, so make it the default. APACHE_MODULE(cgid, CGI scripts, , , yes) diff --git a/server/mpm/MPM.NAMING b/server/mpm/MPM.NAMING index 98ee19921d..328d713c6c 100644 --- a/server/mpm/MPM.NAMING +++ b/server/mpm/MPM.NAMING @@ -5,9 +5,6 @@ The following MPMs currently exist: perchild ...... Multi Process Model with Threading. Constant number of processes, variable number of threads each child process can have a different uid/gid. - threaded ...... Multi Process Model with Threading. - Variable number of processes, constant number of - threads/child (= Apache/thread) spmt_os2 ...... Single Process Model with Threading on OS/2 mpmt_os2 ...... Multi Process Model with Threading on OS/2 Constant number of processes, variable number of threads. diff --git a/server/mpm/config.m4 b/server/mpm/config.m4 index e817817603..887bef18e1 100644 --- a/server/mpm/config.m4 +++ b/server/mpm/config.m4 @@ -1,7 +1,7 @@ AC_MSG_CHECKING(which MPM to use) AC_ARG_WITH(mpm, APACHE_HELP_STRING(--with-mpm=MPM,Choose the process model for Apache to use. - MPM={beos|worker|threaded|prefork|spmt_os2|perchild}),[ + MPM={beos|worker|prefork|spmt_os2|perchild}),[ APACHE_MPM=$withval ],[ if test "x$APACHE_MPM" = "x"; then @@ -12,7 +12,7 @@ AC_MSG_RESULT($APACHE_MPM) apache_cv_mpm=$APACHE_MPM -if test "$apache_cv_mpm" = "threaded" -o "$apache_cv_mpm" = "worker" -o "$apache_cv_mpm" = "perchild"; then +if test "$apache_cv_mpm" = "worker" -o "$apache_cv_mpm" = "perchild"; then APR_CHECK_APR_DEFINE(APR_HAS_THREADS, srclib/apr) if test "x$ac_cv_define_APR_HAS_THREADS" = "xno"; then