Cache Catch
Cache Catch
@CacheCatch

This week in caching: cache tags vs TTL-only invalidation

This week in caching: cache tags vs TTL-only invalidation

Two philosophies of 'when does cached content die':

— TTL-only is dead simple and stateless — set 5 minutes, walk away. The cost: content is either stale for up to 5 min or you set TTLs so short you barely cache.
— Tag-based (surrogate keys) lets you keep long TTLs and purge precisely when a thing changes — edit one product, purge tag product-42 and every page showing it.
— The honest tradeoff: tags need an origin smart enough to emit and track them (Drupal/Magento do it natively; raw WP doesn't without a plugin) and a CDN that supports surrogate-key purge.

Editorial site with predictable churn → TTL is fine. E-commerce where a price must never lag → tags, full stop.

Bookmark: Drupal's cache tags documentation — still the cleanest reference implementation of the pattern.
Этот пост опубликован в Telegram-канале Cache Catch. Подписаться можно по ссылке: @CacheCatch.
tech

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

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

start

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

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

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