Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Apache: Dev

Cacheability and s-maxage

 

 

Apache dev RSS feed   Index | Next | Previous | View Threaded


poirier at pobox

Oct 8, 2009, 12:20 PM

Post #1 of 3 (182 views)
Permalink
Cacheability and s-maxage

I believe a couple of changes are needed in mod_cache to correctly
consider s-maxage in responses. I'd like to get the list's opinion
about it.

First, currently if a GET or HEAD request with a query in the URI has a
response with Cache-control: s-maxage=NN, that response is not cached.
From RFC 2616 13.9, 2nd paragraph, s-maxage specifies an explicit
expiration and so the response should be cached despite the query in the
URI.

Second, currently a successful response with no Last-Modified, Etag, or
Expires headers is not cached. If it has Cache-control: max-age or
Cache-control: s-maxage, that specifies an expiration, and per RFC
2616 13.4 we would expect it to be cached.

I'm attaching a trunk patch that would implement these changes.

--
Dan Poirier <poirier[at]pobox.com>
Attachments: trunk.patch.txt (1.76 KB)


poirier at pobox

Oct 8, 2009, 12:34 PM

Post #2 of 3 (158 views)
Permalink
Re: Cacheability and s-maxage [In reply to]

And here's the right patch file, sorry.

--
Dan Poirier <poirier[at]pobox.com>
Attachments: trunk.patch.txt (1.63 KB)


rpluem at apache

Oct 8, 2009, 1:06 PM

Post #3 of 3 (158 views)
Permalink
Re: Cacheability and s-maxage [In reply to]

On 10/08/2009 08:59 PM, Dan Poirier wrote:
> I believe a couple of changes are needed in mod_cache to correctly
> consider s-maxage in responses. I'd like to get the list's opinion
> about it.
>
> First, currently if a GET or HEAD request with a query in the URI has a
> response with Cache-control: s-maxage=NN, that response is not cached.
>>From RFC 2616 13.9, 2nd paragraph, s-maxage specifies an explicit
> expiration and so the response should be cached despite the query in the
> URI.
>
> Second, currently a successful response with no Last-Modified, Etag, or
> Expires headers is not cached. If it has Cache-control: max-age or
> Cache-control: s-maxage, that specifies an expiration, and per RFC
> 2616 13.4 we would expect it to be cached.
>
> I'm attaching a trunk patch that would implement these changes.
>

Sound reasonable and looks fine (I mean the patch in the second mail of course :-))

Regards

Rüdiger

Apache dev RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.