[HN Gopher] HTTP Caching, a Refresher
___________________________________________________________________
HTTP Caching, a Refresher
Author : danburzo
Score : 27 points
Date : 2025-12-23 19:41 UTC (3 hours ago)
(HTM) web link (danburzo.ro)
(TXT) w3m dump (danburzo.ro)
| baggy_trough wrote:
| A lot of this seems irrelevant these days with https everywhere.
| nerdbaggy wrote:
| These are still used in CDN and internal browser caching
| jarofgreen wrote:
| Some of it is different, but the basics are still the same and
| still relevant. Just today I've been working with some of this.
|
| I took a Django app that's behind an Apache server and added
| cache-control and vary headers using Django view decorators,
| and added Header directives to some static files that Apache
| was serving. This had 2 effects:
|
| * Meant I could add mod_cache to the Apache server and have
| common pages cached and served directly from Apache instead of
| going back to Django. Load testing with vegeta (
| https://github.com/tsenart/vegeta ) shows the server can now
| handle multiples more simultaneous traffic than it could
| before.
|
| * Meant users browsers now cache all the CSS/JS. As users move
| between HTML pages, there is now often only 1 request the
| browser makes. Good for snappier page loads with less server
| load.
|
| But yeah, updating especially the sections on public vs private
| caches with regards to HTTPS would be good.
| esseph wrote:
| Just the opposite, caching is everywhere now. How do you think
| a CDN works?
___________________________________________________________________
(page generated 2025-12-23 23:00 UTC)