[mod_python] ChildInit handler?

Graham Dumpleton graham.dumpleton at gmail.com
Sun Mar 2 15:48:40 EST 2008


On 03/03/2008, Sean Allen <sean at ardishealth.com> wrote:
> Does mod_python support the the apache handler that runs when a new
>  child process is created and the corresponding cleanup handler?

The closest you will get is the PythonImport directive for doing
something when process starts. To register a cleanup on process exit
(if using mod_python 3.3.1) use the function
'mod_python.apache.register_cleanup()'. Note though that no guarantee
that cleanup code will be executed on process shutdown, so you should
not religiously rely on it.

Both features are documented.

Graham


More information about the Mod_python mailing list