httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nick Kew <n...@webthing.com>
Subject Re: Limiting response body length
Date Mon, 12 Feb 2007 21:55:23 GMT
On Mon, 12 Feb 2007 22:09:57 +0100
Henrik Nordstrom <henrik@henriknordstrom.net> wrote:

> mån 2007-02-12 klockan 17:51 +0000 skrev Nick Kew:
> 
> > 2. Where there's chunked encoding, the check would best be
> > implemented in the chunking filter.
> > 
> > 3. A simple count/abort filter is then a last resort.
> > And it won't be able to tell the client what's happened,
> > because the header has already been sent (unless it
> > buffers the entire response, which is horribly inefficient).
> 
> Why differing 2 and 3? What's the benefit of doing it in the chunking
> filter? Just to avoid having yet another filter in the chain or
> something besides that?

Because the chunking filter is equipped to discard the chunk that
takes it over the limit, and substitute end-of-chunking.
If we do that in a new filter, we have to reinvent that wheel.

-- 
Nick Kew

Application Development with Apache - the Apache Modules Book
http://www.apachetutor.org/

Mime
View raw message