]> granicus.if.org Git - apache/commitdiff
More changes to the way that we use mod_status on beos.
authorDavid Reid <dreid@apache.org>
Tue, 13 Feb 2001 20:46:48 +0000 (20:46 +0000)
committerDavid Reid <dreid@apache.org>
Tue, 13 Feb 2001 20:46:48 +0000 (20:46 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@88145 13f79535-47bb-0310-9956-ffa450edef68

server/mpm/beos/mpm.h
server/mpm/beos/mpm_default.h

index 4ea10e4acf81869a86b4bd60acc3eed76251a1a2..20855ac6d1e4cb7fd3a38148da8c9624d2bede63 100644 (file)
 #define APACHE_MPM_BEOS_H
 
 #define BEOS_MPM
+#include "scoreboard.h"
 
 #define MPM_NEEDS_RECLAIM_CHILD_PROCESSES 1
 #define MPM_SYNC_CHILD_TABLE()
-#define MPM_CHILD_PID(i) (ap_scoreboard_image->parent[i].pid)
+#define MPM_CHILD_PID(i) (ap_scoreboard_image->servers[0][i].tid)
 #define MPM_NOTE_CHILD_KILLED(i) (MPM_CHILD_PID(i) = 0)
 
 extern int ap_max_child_assigned;
-#include "scoreboard.h"
 
 extern server_rec *ap_server_conf;
 extern char ap_coredump_dir[MAX_STRING_LEN];
index 02e7f434794c31159872a7af74331379421e3cc9..eef6c1852abaa278a196adac23b5c150d310553c 100644 (file)
 #ifndef APACHE_MPM_DEFAULT_H
 #define APACHE_MPM_DEFAULT_H
 
+/* we use the child (c) as zero in our code... */
+#define AP_ID_FROM_CHILD_THREAD(c, t)     t
+/* as the child is always zero, just return the id... */
+#define AP_CHILD_THREAD_FROM_ID(i)        0 , i
 
-#define AP_ID_FROM_CHILD_THREAD(c, t)    ((c * HARD_THREAD_LIMIT) + t)
-#define AP_CHILD_THREAD_FROM_ID(i)       (0),(i)
-
-/* Number of servers to spawn off by default --- also, if fewer than
+/* Number of threads to spawn off by default --- also, if fewer than
  * this free when the caretaker checks, it will spawn more.
  */
-#ifndef DEFAULT_START_DAEMON
-#define DEFAULT_START_DAEMON 5
+#ifndef DEFAULT_START_THREADS
+#define DEFAULT_START_THREADS 25
 #endif
-#define DEFAULT_START_THREADS 20
 
-/* Maximum number of *free* server processes --- more than this, and
+/* Maximum number of *free* threads --- more than this, and
  * they will die off.
  */
 
-#ifndef DEFAULT_MAX_FREE_DAEMON
-#define DEFAULT_MAX_FREE_DAEMON 10
+#ifndef DEFAULT_MAX_FREE_THREADS
+#define DEFAULT_MAX_FREE_THREADS 50
 #endif
 
 /* Minimum --- fewer than this, and more will be created */
 
-#ifndef DEFAULT_MIN_FREE_DAEMON
-#define DEFAULT_MIN_FREE_DAEMON 5
+#ifndef DEFAULT_MIN_FREE_THREADS
+#define DEFAULT_MIN_FREE_THREADS 5
 #endif
 
 /* Limit on the total --- clients will be locked out if more servers than
  * enough that we can read the whole thing without worrying too much about
  * the overhead.
  */
-#ifdef NO_THREADS
-#define HARD_SERVER_LIMIT 256
-#endif
-#ifndef HARD_SERVER_LIMIT
-#define HARD_SERVER_LIMIT 64 
-#endif
+
+/* we only ever have 1 main process running... */ 
+#define HARD_SERVER_LIMIT 1
 
 /* Limit on the threads per process.  Clients will be locked out if more than
  * this  * HARD_SERVER_LIMIT are needed.
 #define HARD_THREAD_LIMIT 1
 #endif
 #ifndef HARD_THREAD_LIMIT
-#define HARD_THREAD_LIMIT 64 
+#define HARD_THREAD_LIMIT 50 
 #endif
 
 #ifdef NO_THREADS