httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: AddOutputFilter hook needed?
Date Tue, 19 Sep 2000 17:23:54 GMT

> For some reason it took me a while to grasp what Ryan was saying
> yesterday about why there is no need for the insert_filter hook, but I
> think I agree with him.
> There is no new information available to the module at
> insert_filter-hook time, so the module could have just as well decided
> to add the filter during a previous hook. 

YES!  This is exactly it.  So, did it take a while because I wasn't
describing it well enough?  From reading Greg's message earlier today, I
got the impression that I wasn't describing what was needed well
enough.  Did my response solve that?

> mod_charset_lite has always made decisions at fixup_hook-time.  Why
> not go ahead and insert the filter there?  For any module, why not
> insert the filter at the point where the module decides the filter is
> needed instead of wait until the insert_filter hook is called?

This requires a few other changes of course.  :-)

First of all, the core needs to be modified to add it's filters in the
post_read_request phase (should take about two seconds).

Second, ap_add_filter needs to change to insert filters at the top of the
stack.  This is the only way things make sense, because it means that we
can insert the core filters and all of the filters that were added with a
core directive at the beginning of the request, and then we can add more
filters on top of those.  Adding filters at the bottom of the stack won't
work if we remove the insert_filters hook.


Ryan Bloom               
406 29th St.
San Francisco, CA 94131

View raw message