httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Issac Goldstand <>
Subject Re: mod_cache responsibilities vs mod_xxx_cache provider responsibilities
Date Wed, 20 Sep 2006 18:23:17 GMT

Brian Akins wrote:
> Issac Goldstand wrote:
>> I don't understand why bother getting so complex.  Touch/truncate the
>> body file when storing the header, and then a missing body means things
>> have gone amok - retry the request.  Conversely, a zero-length, or < C-L
>> body length means another thread is working on the body.
> unless 0 is a valid content-length, which it can be. 

In that case, we'll know that from having read the header file.
Frankly, in that case we don't even need to look for a data file, as an
optimization, and can even probably safely delete the empty file.

> Also, what about
> when we are reading something in without a know C-L, for example from an
> origin doing chunks?

We'll know it's chunked, and the possibility of getting a chunked body
of 0 length and not having the initial 0 chunk length immediately
following the headers from the response is pretty slim, IMHO.

For any other length we don't introduce any problem we don't have now.

>>  > You're right, this is a tricky one, but there is a solution out there.
>> Maybe we're attacking the problem from the wrong angle.  Rather than
>> modifying mod_cache, modify the garbage-collector (e.g.,
>> htcacheclean). Do a two pass cleanup. 
> I think it's insane that it has to traverse the directory structure to
> do find the objects.  There should be an index of objects.  Traversing
> the tree can be a huge hit on large, busy structures.

View raw message