Redis appears in almost every eCommerce stack we review. What differs enormously is how well it is used. A cache layer can reduce database load by an order of magnitude — or it can hide problems, serve stale data and add a new failure mode. The difference is strategy.
What belongs in Redis — and what does not
Good candidates share three properties: they are read far more often than written, they are expensive to compute, and staleness is acceptable for a defined window. In commerce platforms, that typically means sessions, computed prices for anonymous users, category trees, configuration and rendered fragments.
Poor candidates are the opposite: stock levels during a flash sale, cart contents, anything involved in payment. Caching these trades correctness for speed — the wrong trade in a shop.
The patterns that matter in production
Explicit TTLs and invalidation rules
Every cached item needs an answer to two questions: how long may this be stale, and what event must invalidate it? If a team cannot answer those questions for a cache key, that key is a future incident.
Cache stampede protection
When a popular key expires under load, hundreds of requests may recompute it simultaneously — briefly multiplying database load exactly when a campaign peaks. Locking, probabilistic early expiration or serving stale-while-revalidate solve this. Most platforms we audit have no protection at all.
Redis as infrastructure, not an afterthought
Memory limits, eviction policies and persistence settings need deliberate choices. An eviction policy that silently drops session keys produces “randomly logged out” bug reports that teams chase for months.
A note on measuring
Cache hit rate alone is a vanity metric. What matters is the effect on the protected resource: database query volume, p95 response times on uncached paths, and behavior during invalidation storms. We measure before and after every caching change — assumptions about cache effectiveness are wrong surprisingly often.
Takeaway
Redis is not a performance strategy by itself. A deliberate answer to “what is cached, for how long, invalidated by what” is. Get that right, and Redis becomes the highest-leverage component in your stack.





