简体   繁体   English

max-age,no-Cache,必须在Cache-Control Header上重新验证,在此优先?

[英]max-age, no-Cache,must-revalidate on Cache-Control Header, Which takes predence here?

Cache-Control : max-age=86400, no-store, must-revalidate, no-cache 缓存控制:max-age = 86400,无需存储,必须重新验证,无需缓存

This is a response header set by the server for a JS file. 这是服务器为JS文件设置的响应标头。

Does it mean the response is cached for 86400 seconds before revalidating?. 这是否意味着响应在重新验证之前已缓存了86400秒?

Which of the above one takes precedence and what is the resiult?. 以上哪一个优先,结果如何?

Looks like no-cache is give precedence over all. 看起来no-cache优先于所有。 HTTP1.1 specification says " If the no-cache directive does not specify a field-name, then a cache MUST NOT use the response to satisfy a subsequent request without successful revalidation with the origin server. " Refer http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9.1 HTTP1.1规范说:“ If the no-cache directive does not specify a field-name, then a cache MUST NOT use the response to satisfy a subsequent request without successful revalidation with the origin server. ”请参阅http://www.w3。 .ORG /协议/ RFC2616 / RFC2616-sec14.html#sec14.9.1

It also says " The max-age directive on a response implies that the response is cacheable (ie, "public") unless some other, more restrictive cache directive is also present. " Refer http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.9.3 它还说,“ The max-age directive on a response implies that the response is cacheable (ie, "public") unless some other, more restrictive cache directive is also present. ”参见http://www.w3.org/Protocols /rfc2616/rfc2616-sec14.html#sec14.9.3

All the above are for HTTP/1.1 . 以上所有都是针对HTTP / 1.1的。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 HTTP Cache-Control 标头 max-age 与 max-age,必须重新验证 - HTTP Cache-Control header max-age vs max-age, must-revalidate HTTP缓存控制的最大使用期限,必须重新验证 - HTTP Cache Control max-age, must-revalidate “no-cache”vs“max-age = 0,must-revalidate,proxy-revalidate” - “no-cache” ​vs “max-age=0, must-revalidate, proxy-revalidate” 同时使用“ Expires:0”,“ no-cache”,“ no-store”,“ max-age = 0,必须重新验证”-做什么用? - Simultaneous use of “Expires: 0”, “no-cache”, “no-store”, “max-age=0, must-revalidate” - what for? 在“Cache-Control:no-cache,must-revalidate”中使用“must-revalidate”是多么必要 - How necessary it is to use “must-revalidate” in “Cache-Control: no-cache, must-revalidate” 即使使用Etag,更改静态文件的URL仍然返回304,max-age:0,必须重新验证和无缓存 - Changed static file's URL still returns 304 even with Etag, max-age: 0, must-revalidate and no-cache Cache-Control: max-age=0 和 no-cache 有什么区别? - What's the difference between Cache-Control: max-age=0 and no-cache? no-cache 和 must-revalidate 之间的区别 - Difference between no-cache and must-revalidate CloudFront “年龄” header 对“缓存控制:私有; 最大年龄=3600” - CloudFront “age” header effect on “cache-control: private; max-age=3600” http请求中的cache-control:max-age = 0和If-Not-Modified - cache-control:max-age=0 and If-Not-Modified in http request
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM