The site re-downloading 4MB it already had cached
A documentation portal in Oslo had decent hit ratios but slow repeat visits. Returning readers re-fetched 4MB of unchanged assets every session.
We tuned conditional revalidation:
— Confirmed origin emitted strong ETag and Last-Modified on every asset
— Enabled the edge to answer If-None-Match with a 304 instead of re-streaming the body
— Added immutable to hashed assets so browsers skipped revalidation entirely
— For HTML, kept revalidation on but made it a 304 (200 bytes) not a 200 (40KB)
— Verified with a repeat-load waterfall that bodies became 304s
Repeat-visit transfer dropped from 4MB to 60KB — almost everything answered 304 Not Modified or came from browser cache. Repeat-load time in Oslo fell by 1.1s. Revalidation is nearly free when it returns 304; the waste is re-sending bodies that haven't changed.
The number that mattered: 98.5% of repeat-visit bytes eliminated by honoring ETags.
Edge of Glory
@EdgeOfGloryCDN
The site re-downloading 4MB it already had cached
Этот пост опубликован в Telegram-канале Edge of Glory. Подписаться можно по ссылке: @EdgeOfGloryCDN.