In HTTP 1.1, the Expires header was deprecated and Cache-Control is the alternative. If both Expires and Cache-Control headers are found, Expires will be ignored.by flierps - Nginx Mailing List - English
When max-age=0 in the Cache-Control header, Nginx will not cache, so that will not work. I need this in cache-control to make sure all browsers will revalidate. So, as far as I can see I can chose between: 1. ignore cache-control header, need to set proxy_valid or nothing will be cached minimum is 1s. 2. not ignore cache-control, but obliged to set max-age or nothing will be cached minimum iby flierps - Nginx Mailing List - English
Yes, upstream behaves as you would expect. Right now Nginx proxy_valid is set to 1 second. After that second Nginx revalidates with upstream and upstream will respond with 304 if applicable. I just do not want Nginx to serve from cache during that second. It always needs to revalidate. Apache supports this as noted here by somebody else: https://stackoverflow.com/questions/41252208/nginx-by flierps - Nginx Mailing List - English
Nginx will not cache content when max-age=0 although I believe this should be standard in combination with must-revalidate. I want to cache dynamic content, so every request needs to be revalidated. This way when I get multiple fresh GET requests for an expensive resource, Nginx can revalidate with the backend that only needs to generate a 304's and the full content can be served to the clientsby flierps - Nginx Mailing List - English