httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Graham Leggett" <minf...@sharp.fm>
Subject Re: [PATCH]: mod_cache: don't store headers that will never be used
Date Mon, 30 Jul 2007 09:07:08 GMT
On Mon, July 30, 2007 10:40 am, Niklas Edmundsson wrote:

>> What may make this workable is the combination of "The body is NOT
>> stale"
>> with "max-age=0". The danger of not writing the headers is that an
>> entity,
>> once stale, will not be freshened when the spec says it should, and will
>> cause a thundering herd of conditional requests to a backend server.
>> This
>> issue has been badly understood by some in the past, who suggested that
>> the
>> ability to update cached entities be removed. We need to make very sure
>> that
>> by fixing one problem we don't introduce another.
>
> You missed the condition that the header wasn't expired, right?

Alas wrong - the text above was cut and pasted from what you've quoted below.

> To
> reiterate:
> - The body is NOT stale (ie. HTTP_NOT_MODIFIED when revalidating)
> - The on-disk header hasn't expired.
> - The request has max-age=0
>
> Since the on-disk header hasn't expired AND the body is unchanged,
> you'll have the same data in the cache except for the Expires header.

The problem as Roy pointed out is that max-age=0 is used by code to
freshen caches, even caches that are "almost stale". As I said above, we
need to make very sure that by fixing one problem we are not introducing
another.

Regards,
Graham
--



Mime
View raw message