The cache key that fragmented into 40,000 copies
A SaaS docs site in Dublin had a 22% hit ratio and nobody knew why. The edge was storing 40,000 versions of the same 600 pages.
The fix was a cache-key normalization checklist:
— Sorted query parameters alphabetically so ?a=1&b=2 and ?b=2&a=1 shared one key
— Stripped 31 known tracking params (utm_*, gclid, fbclid, mc_cid)
— Lowercased the host and removed the default port from the key
— Dropped Accept-Language from the key for English-only pages
— Ignored cookies entirely on documentation routes
With the key collapsed, those 40,000 fragments became 600 real cache entries. Hit ratio climbed to 95% inside an hour. Audit your key composition first — a wrong Vary or a stray param multiplies storage and tanks hits silently. Nothing in origin changed.
The number that mattered: 39,400 phantom cache entries that vanished overnight.
Edge of Glory
@EdgeOfGloryCDN
The cache key that fragmented into 40,000 copies
Этот пост опубликован в Telegram-канале Edge of Glory. Подписаться можно по ссылке: @EdgeOfGloryCDN.