On 16 Jun 2010, at 12:49 PM, Joe Orton wrote:

The core output filter should coalesce "small" writes already and if
it's not doing that effeciently that's a bug. Are the "tiny" files you
were seeing getting sendfile()d out bigger than AP_MIN_SENDFILE_BYTES?
That sounds like a case for bumping up AP_MIN_SENDFILE_BYTES.

Many of the packets consisted of a CRLF followed by an indentation tab, and were only a few bytes long. The core output filter is too late in the chain to make any difference, as the response had already been turned by the chunking filter into hundreds of little chunks, consisting of a heap bucket (chunk header), followed by a file bucket (the original content), followed by an immortal bucket (trailing CRLF), etc.

The fix was to simply buffer up the fragmented output directly after the fragments where created, and let the rest of the filter stack step in and work as efficiently as possible on as few buckets as possible.

Regards,
Graham
--

Reply via email to