Re: [whatwg/fetch] {cache: "no-cache"} vs Cache-Control: immutable (#308)

Having worked in the TCP accelerator biz for a while (Orbital Data/Citrix Repeater), my take is a little different: "Just because the Web site is messed up doesn't mean the users don't deserve decent performance."

The question was about no-cache, but let's shift over to max-age for a moment, where the hack I have in mind is less messy. Suppose the browser treated:

Cache-Control: max-age=0, immutable

as if it were:

Cache-Control: max-age=0, stale-while-revalidate=[1 year]

This would give all the user-visible performance of immutable because the stale resource is served from the cache and the revalidation is done after the fact.

Now, some of the value of "immutable" is to prevent the revalidations altogether, which this doesn't do. But I suspect that something can be done about this as well...

With no-cache, I'd want some reasonably strong tie-breaker before I paid any attention to immutable: no-cache + immutable + something else. 

That's browser object-loading behavior, where shift-reload cures all ills. In a client-side app, I'd be more cautious. Of course, with a client-side app, I'd want things to work even if the response's Cache-Control header had been rewritten or dropped by an intervening proxy, so I'd ignore immutable, max-age, etc. except on objects I already thought of as highly cacheable.

Robert

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/issues/308#issuecomment-243189824

Received on Monday, 29 August 2016 17:18:13 UTC