The only way to register cleanup methods to be executed upon child termination
is through req.server.register_cleanup(). Since the cleanup method isn't specific
to a request, it seems that there should also be an apache.register_cleanup(). This
would allow cleanup function registration upon child termination to be done from
a module imported using the PythonImport directive.