mpm_common.c

Checkout Tools
  • last updated 1 hour ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates

Changeset 1180687 is being indexed.

Consistently use base 10 for numbers when parsing config options. It may be

confusing to the user if some directives treat a number with leading zero as

octal while most don't.

  1. … 4 more files in changeset.
Add -D DUMP_RUN_CFG option to dump some configuration items

from the parsed (or default) config. This is useful for init scripts that

need to setup temporary directories and permissions, for example if those

temporary directories are located on a ram disk.

  1. … 10 more files in changeset.
Export ap_max_mem_free, needed by r1178079, as pointed out by Gregg L. Smith

  1. … 2 more files in changeset.
* server/mpm_common.c (ap_core_child_status): Allocate the geninfo,

unused_geninfo ring heads from the heap; fixing gcc aliasing

warnings.

Log the deprecation warning at level info, not warn

  1. … 3 more files in changeset.
Introduce ap_(get|set)_core_module_config() functions/macros and use them

everywhere.

We know that the core module has module_index 0. Therefore we can save

some pointer operations in ap_get_module_config(cv, &core_module) and

ap_set_module_config(cv, &core_module, val). As these are called rather often,

this may actually have some (small) measurable effect.

  1. … 42 more files in changeset.
disable hook probes for our two hooks which have no args

Reviewed by: jim

  1. … 1 more file in changeset.
Add child_status hook for tracking creation/termination of MPM child

processes. Add end_generation hook for notification when the last

MPM child of a generation exits.

end_generation is implemented completely by core using the

child_status hook run by the MPM.

simple and mpmt_os2 MPMs don't currently run the child_status

hook, so neither hook is invoked with those MPMs.

  1. … 11 more files in changeset.
Abort if the MPM is changed across restart.

A new MPM can't be expected to manage the existing state,

particularly if that includes processes from the previous

generation.

  1. … 1 more file in changeset.
Simplify the interface to ap_reclaim_child_processes() and

ap_relieve_child_processes(): instead of requiring the MPM

to implement an otherwise-useless hook, just use a callback

function.

As I don't expect third-party MPM devs are following our day

to day progress, the API changes are considered part of

yesterday's MMN change.

  1. … 7 more files in changeset.
the mpm-note-child-killed hook was just for use by

ap_{reclaim,relieve}_child_processes; those functions can

invoke the hook directly; the function ap_mpm_note_child_killed()

is useless

  1. … 3 more files in changeset.
mpm_common.c implements a handful of config directives; the

related state has to be re-initialized to the default values

at pre-config time, but that was handled inconsistently by

the MPMs, resulting in unexpected behavior when some of the

directives were removed across restart

move that necessary initialization from the MPMs to common

code run from core's pre-config; MPMs that need to override

defaults can do so by running after core's pre-config (the

NetWare MPM now does that)

the DEFAULT_MAX_REQUESTS_PER_CHILD compile setting wasn't useful

enough to keep

the simple MPM wasn't consistent in which of these directives

were respected and which weren't, and that hasn't changed

(see procmgr.max_requests_per_child vs. ap_max_requests_per_child)

  1. … 15 more files in changeset.
use apr_time_from_sec() shortcut

Added prototype for initgroups().

  1. … 1 more file in changeset.
Rename MaxRequestsPerChild to MaxConnectionsPerChild, which

describes more accurately what the directive does.

The old name still works but logs a warning.

  1. … 20 more files in changeset.
core: Abort with sensible error message if no or more than one MPM is

loaded.

  1. … 4 more files in changeset.
remove more unused variables

revove some obsolete comments

netware file is untested

  1. … 12 more files in changeset.
Use the new APLOG_USE_MODULE/AP_DECLARE_MODULE macros everywhere to take

advantage of per-module loglevels

  1. … 169 more files in changeset.
Refactor mod_status out of the ExtendedStatus toggle picture, as other

modules can and should be able to use this scoreboard information.

Rename suggestions for such a directive are welcomed.

Note that mod_status toggles the default, to present the ExtendedStatus

for server operators, whenever it is loaded. Docs changes to follow.

  1. … 5 more files in changeset.
Replace AcceptMutex, LockFile, RewriteLock, SSLMutex, SSLStaplingMutex,

and WatchdogMutexPath with a single Mutex directive. Add APIs to

simplify setup and user customization of APR proc and global mutexes.

(See util_mutex.h.) Build-time setting DEFAULT_LOCKFILE is no longer

respected; set DEFAULT_REL_RUNTIMEDIR instead.

Some existing modules, such as mod_ldap and mod_auth_digest gain

configurability for their mutexes.

  1. … 30 more files in changeset.
Hmmm... forgot git commit/dcommit.

  1. … 1 more file in changeset.
Enhance ap_hook_monitor to pass along a server_rec (in

general the ap_server_conf) and tuck away some storage

in there which may be useful as an opaque data pointer.

  1. … 9 more files in changeset.
Bring back OS/2 support.

Reverses r758929 with a little bit of conflict resolution.

  1. … 37 more files in changeset.
main() can use ap_run_mpm() directly, so axe the old ap_mpm_run() function

change the mpm hooks to return OK/DONE instead of 0/1

  1. … 9 more files in changeset.
mpm-query hook: distinguish between DECLINED and APR_ENOTIMPL so that

. ap_mpm_query() can return APR_EGENERAL if called too early (for debugging a module)

. some hypothetical module which implements the mpm-query hook can bypass the MPM

with APR_ENOTIMPL

  1. … 7 more files in changeset.
the mpm_get_child_pid hook is unnecessary, as was the per-MPM MPM_CHILD_PID() macro which it replaced

axe this new hook, and use ap_get_scoreboard_process() instead

  1. … 5 more files in changeset.
axe unmaintained 1.3-era code to support AUX, SunOS, IRIX, Next, Tandem, MPE,

LynxOS, QNX, and UnixWare

  1. … 10 more files in changeset.
remove TPF support
  1. … 15 more files in changeset.
remove OS/2 platform support

  1. … 31 more files in changeset.
remove BeOS OS support

  1. … 13 more files in changeset.