Cache Catch
Cache Catch
@CacheCatch

This week in caching: private browser cache vs shared CDN cache

This week in caching: private browser cache vs shared CDN cache

The header nuance that causes the most cache bugs:

— Cache-Control: private means only the user's browser may store it — correct for logged-in dashboards. A CDN must skip it.
— public opens it to shared caches (CDN, proxies) — correct for anonymous pages.
— The killer: s-maxage overrides max-age for shared caches only. So you can tell the CDN 'cache 1 hour' while telling browsers 'cache 1 minute' — long edge life, fresh-ish clients, no header conflict.

Classic outage: serving a logged-in page as public and leaking one user's cart to everyone behind the CDN. Always pair user-specific responses with private AND a Vary on the auth cookie.

Bookmark: MDN's Cache-Control reference — keep the private/public/s-maxage section open while you debug.
Этот пост опубликован в Telegram-канале Cache Catch. Подписаться можно по ссылке: @CacheCatch.
tech

Свежие посты в категории «Tech Infrastructure»

Все каналы категории →

start

Готовы запустить рекламу через сеть public.tg?

Новый оффер, продукт, GEO, кейс, событие или партнёрский запуск — соберём маршрут под задачу и отдадим медиаплан.

Telegram для медиаплана: @AFFtop_connect. Быстрый тест: $20 за канал, $1000 за пакет по сети.