Menu

Redis Hot Keys: Why Adding More Nodes Doesn't Always Help
πŸ“°

Redis Hot Keys: Why Adding More Nodes Doesn't Always Help

DEV Community: redisΒ·AbhinavΒ·8 days ago
#MiUM7UoS
#devtoredis#devto#dev#node#product
Reading 0:00
15s threshold

Imagine we're building an e-commerce application.

We use Redis to cache product details so that our application doesn't have to query the database every time someone opens a product page.

Everything works well until one product suddenly goes viral.

A product that normally receives 1,000 requests per second now receives 100,000 requests per second.

Our Redis cluster has multiple nodes. Some of them are barely doing any work. Yet one node is struggling to keep up.

Why?

The answer lies in a concept called hot keys .

In this article, we'll understand how Redis distributes keys, why a single key can become a bottleneck, and how we can distribute the load without simply adding more Redis nodes.

1.…

Continue reading β€” create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.