Live data from Hacker News

HTTP Caching, a Refresher

danburzo.ro

11–20 of 34 posts

Re: HTTP Caching, a Refresher

#11
post #7

As is traditional with most explanations of HTTP caching, it doesn't mention Vary header. Although apparently some CDNs (e.g. Cloudflare) straight up ignore it for some reason [0]. [0] https://news.ycombinator.com/item?id=38346382

Vary is Very important.

> the cache MUST NOT use that stored response without revalidation unless all the presented request header fields nominated by that Vary field value match those fields in the original request

You’ll find that some have creative readings of MUST NOT.

Re: HTTP Caching, a Refresher

#12
post #7

As is traditional with most explanations of HTTP caching, it doesn't mention Vary header. Although apparently some CDNs (e.g. Cloudflare) straight up ignore it for some reason [0]. [0] https://news.ycombinator.com/item?id=38346382

Good call! Honestly I just wanted to wrap it up before the holidays, but you’re right that a small section on Vary would have been useful.

Things like non-conforming caching services made me punt actual suggestions to a later article, as I wasn’t sure how my sense of the RFC interacted with the real world. HTTP Caching Tests seems like a great resource for this, but only includes Fastly out of the big providers, and it seems to be doing okay with Vary. https://cache-tests.fyi/

Re: HTTP Caching, a Refresher

#13
post #6

A lot of this seems irrelevant these days with https everywhere.

how is https making caching irrelevant?

At one point with http only your isp could do its own cache, large corporate it networks could have a cache, etc. which was very efficient for caching. But horrible for privacy. Now we have CDN edge caching etc but nothing like the multi layer caching that was available with http.

Re: HTTP Caching, a Refresher

#14
As many have pointed out here, the nature of caching has changed in the current climate of ubiquitous HTTPS, and I want to add a paragraph or two about it. Is there a good summary somewhere that I could reference? What are the the usual, most prevalent uses of HTTP intermediaries involving caches, besides CDNs and origin-controlled caches (eg Varnish)?

Re: HTTP Caching, a Refresher

#15

A lot of this seems irrelevant these days with https everywhere.

If you implement any of the ends of a HTTP communication caching is still very important.

This website is chock full of site operators raging mad at web crawlers created by people that didn't bother to implement proper caching mechanisms.

Re: HTTP Caching, a Refresher

#16

A lot of this seems irrelevant these days with https everywhere.

CDNs manage user TLS certificates and that is one of the advantages of using them.

A node server could negociate https close to the user, do caching stuff and create an other https connection to your local server (or reuse an existing one).

Https everywhere with your CDN in middle.

Re: HTTP Caching, a Refresher

#17
post #7

As is traditional with most explanations of HTTP caching, it doesn't mention Vary header. Although apparently some CDNs (e.g. Cloudflare) straight up ignore it for some reason [0]. [0] https://news.ycombinator.com/item?id=38346382

There was a recent discussion on X about this that had a couple of Cloudflare people chip in, including their CTO:

https://xcancel.com/simonw/status/1988984600346128664

Re: HTTP Caching, a Refresher

#18

This is nothing new and doesn't add anything new to the topic, so am I the only that thinks this is just an attempt at boosting their SEO through HN?

It clearly notes that it's "a refresher", does not claim that it's novel research, and extensively links to the reference documents. It is, essentially, a review article (https://en.wikipedia.org/wiki/Review_article). And there's absolutely nothing wrong with that.

Hell, the author could probably have called it a primer and I think it'd have been fair.

Re: HTTP Caching, a Refresher

#19
post #7

As is traditional with most explanations of HTTP caching, it doesn't mention Vary header. Although apparently some CDNs (e.g. Cloudflare) straight up ignore it for some reason [0]. [0] https://news.ycombinator.com/item?id=38346382

There was a recent discussion on X about this that had a couple of Cloudflare people chip in, including their CTO: https://xcancel.com/simonw/status/1988984600346128664

The highlight from that thread https://xcancel.com/dok2001/status/1989005141450846470#m
Post reply on HN