On Sun, 27 Feb 2005 14:11:49 -0800, Paul Querna <[EMAIL PROTECTED]> wrote:
> I think extending ExtendedStatus to take [time,uri,module,phase] or
> something like it might be the best route. ('on' could easily set
> options for backwards compat).
defer those details until it is obvious that others agree to butcher
the codebase this way ;)
> I agree that knowing the actual module name would be the most helpful...
> But I am not sure of a clean way yet.
maybe it is not so hard... I have to admit to major blockage when I
look at the hook macros, and it probably isn't such a big deal...
have the apr-util hook macros spit out the normal
namespace_run_access_checker()
as well as
namespace_run_access_checker_extended()
The latter takes a callback function as an extra parameter, and that
callback function is called prior to every hook to pass in
pHook[n].szName + hook name + the parameters to that hook (to get r->
or c-> or whatever), and that callback is called again when the loop
is completed with NULL as the szName parameter.
so Apache code would be
if (module_tracking_enabled) {
access_status = ap_run_access_checker_extended(r, ap_request_tracker);
}
else {
access_status = ap_run_access_checker(r);
}
or set the callback function to NULL when not enabled and have the
extended hook run function in aprutil check for NULL before calling
the callback
access_status = ap_run_access_checker_extended(r, ap_request_tracker_ptr);