httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cliff Woolley <cliffwool...@yahoo.com>
Subject Re: [PATCH] Rework httpd buckets/filtering
Date Mon, 24 Sep 2001 03:35:32 GMT
On Sun, 23 Sep 2001, Greg Stein wrote:

> > > +APU_DECLARE(apr_status_t) apr_brigade_to_buffer(apr_bucket_brigade *b,
> > > char *c); +
>
> Ryan said this should take a reading mode. I don't understand why that
> should be necessary. You have a brigade of a defined size, and you're
> flattening that much data. You're already past the point of non-blocking
> reads being used.

FWIW, I agree with Greg on this point.  I can't see any point to allowing
nonblocking mode, just as there's no point to allowing nonblocking mode in
apr_brigade_partition or apr_brigade_length.  What good would nonblocking
mode be?  If you really want the brigade flattened out that bad, then you
REALLY want it flattened... you don't want half of it flattened.

But more importantly, you have to REALLY want it flat in the first place.
IMO adding a function like this encourages lazy coders to abuse it so that
they don't have to deal with things spanning buckets.  If mod_include just
flattened the brigade it worked on it would be a much simpler module.
But it would suck for performance and break our whole zero-copy mantra.
I'm -0 for adding a function like this to the buckets API.

--Cliff

--------------------------------------------------------------
   Cliff Woolley
   cliffwoolley@yahoo.com
   Charlottesville, VA






Mime
View raw message