Nginx proxy cache doesn't update cache-control max-age time!

Maxim Dounin mdounin at mdounin.ru
Mon Apr 6 18:35:14 UTC 2020


Hello!

On Mon, Apr 06, 2020 at 12:25:44PM -0500, J.R. wrote:

> > There is no Age header support in nginx as of now (relevant ticket
> > in Trac: https://trac.nginx.org/nginx/ticket/146).  If you want
> > pages to expire at a specific time regardless of intermediate
> > caching, consider using the "Expires" header.
> 
> The 'age' header appears to be something else... What I'm talking
> about specifically is part of the 'cache-control' header...
> 
> For example:  "cache-control: max-age=9848, public, must-revalidate"
> 
> Without max-age decrementing while in the nginx proxy cache, all
> client will receive the same cached number until the cache is
> refreshed.

The Age header is the HTTP/1.1 way to decrement effective value of 
max-age, see here:

https://tools.ietf.org/html/rfc7234#section-4.2.3

-- 
Maxim Dounin
http://mdounin.ru/


More information about the nginx mailing list