Myth: longer TTLs always improve hit rate
This week in caching, the TTL maximalists:
— The logic: bump every TTL to a week and you'll serve more from cache.
— The correction: hit rate is bounded by working-set size against cache capacity, not by TTL. Past a point, longer TTLs just hold cold entries that evict your hot ones, dropping the ratio that matters.
— Worth your time: watch evictions and key churn, not just TTL. If your eviction rate is high, longer TTLs make it worse.
Bookmark: TTL controls freshness; capacity controls hit rate. Tune the LRU/LFU policy and memory ceiling before you touch expiry times.
Cache Catch
@CacheCatch
Myth: longer TTLs always improve hit rate
Этот пост опубликован в Telegram-канале Cache Catch. Подписаться можно по ссылке: @CacheCatch.