Scrivio Interview library
LeadershipAdvanced6 min read · updated 13 November 2026

In one quarter a shared Redis platform used by 80 services had three incidents: a 6 GB sorted set that blocked a node when deleted, a hot key that saturated one shard during a promotion, and a 2 GB list that broke a resharding.

What standards, tooling and ownership would you put in place so big and hot keys are caught before they cause incidents?

I would publish clear limits with the reasons behind them, such as a default maximum of 1 MB per value and 10,000 elements per key with required TTLs and approved patterns for large data. I would automate detection with nightly offline RDB analysis and hot-key signals that report to the owning team, make every key traceable through prefixes and per-service ACL users, protect the platform with lazyfree settings, command restrictions and buffer limits, and handle exceptions through design review rather than outright bans.

Why this question is asked

Three incidents in a quarter from the same family of problem is a signal that the platform lacks rules, not that three teams were careless. Interviewers ask this leadership question to see whether we can turn incident lessons into standards that 80 services will actually follow, with tooling that catches problems early and ownership that makes someone responsible. In this answer, we will look at what the three incidents have in common, then build the standards, the detection, the traceability, the platform protections and the review process, and see how they fit together.

1What the Three Incidents Have in Common

A 6 GB sorted set blocked a node when it was deleted, because freeing tens of millions of elements with DEL runs on the main thread. A hot key saturated one shard during a promotion, because one key lives on one primary. A 2 GB list broke a resharding, because a key must move between nodes as a whole, and moving 2 GB in one MIGRATE call blocks both nodes and can time out.

None of these keys became big or hot overnight. Each grew for weeks or months, invisible because no one was looking, and owned by a team that did not know the platform's limits. So the response has four parts: say what the limits are, detect when keys approach them, know who owns each key, and make the platform survive the cases that slip through.

2Publishing Limits, With Reasons

Standards work when people understand them. A short platform document sets defaults: values up to 1 MB, collections up to 10,000 elements, a TTL on every key on shared clusters, and no unbounded growth. Next to each limit it explains the reason in one sentence: a 6 GB key blocks the node for seconds on delete; a key over a few hundred MB cannot be resharded safely; one key is one thread.

It also gives approved patterns for the cases where data is naturally large: split a large collection into buckets by time or by id (events:2026-11-12:07), page through data instead of storing all of it in one key, and store big documents in a database or object store with only an index in Redis. A team that hits a limit then has a known way forward instead of a debate.

3Automating Detection

Nightly, a job takes the latest RDB snapshot from a replica of each cluster and runs an offline analysis. It produces, per key prefix, the largest keys, their element counts and bytes, keys without TTL, and the change since the previous night. A key that is still within limits but has doubled in a week is the most valuable finding, because it can be fixed before it becomes an incident. The report is sent to the owning team, not only to the platform team.

Hot keys need a live signal. Where clusters run an LFU policy, sampled OBJECT FREQ readings or redis-cli --hotkeys on a replica work; elsewhere, client libraries report request counts per key prefix as metrics, and an alert fires when one key's share of a shard's commands passes a threshold. Before planned events such as promotions, teams run a short review of the keys the event will hit.

Step throughFrom a growing key to an owned fix
  1. Nightly RDB analysis on replicaslargest and fastest-growing keys per prefix
  2. Within limits and stable?
    Yesno actionNoreport to owning team
  3. Owner fixes or requests an exceptionsplit, page, move, or justify
  4. Exception approved in design review?
    Yesrecorded with a review dateNofix scheduled
  5. Next nightgrowth checked again

5 steps in order. Play them, or step through them one at a time.

4Making Every Key Traceable

Detection is useless if a report says the biggest key is tmp:883 and nobody knows whose it is. So every service uses its own key prefix, registered in a simple catalogue with the owning team, and connects with its own ACL user. ACL users can also be restricted to their prefixes with key patterns, for example ~orders:* for the orders service, which prevents one service from writing into another's space.

With prefixes and users in place, every key in a report and every command in a slow log or a CLIENT LIST maps to a team. That turns platform incidents into conversations with a specific owner.

5Protecting the Platform

Some cases will slip through, so the platform should limit the damage. lazyfree settings (lazyfree-lazy-user-del, lazyfree-lazy-expire, lazyfree-lazy-eviction, lazyfree-lazy-server-del) move freeing of large values to background threads, so deleting a 6 GB key no longer blocks the node. ACLs deny KEYS, FLUSHALL, FLUSHDB and MONITOR to application users. client-output-buffer-limit for normal clients and maxmemory-clients stop a huge reply from evicting data.

Resharding procedures check key sizes in the slots being moved before starting, and large keys are split or moved in a planned window first.

Each incident and the control that prevents it
IncidentDetectionProtection
6 GB sorted set blocked on deletenightly size report and growth alertlazyfree settings, UNLINK
Hot key saturated a shardper-prefix request metrics, LFU samplingpre-event review, local caching, split keys
2 GB list broke reshardingsize limits in nightly reportpre-migration key size check

6Exceptions Through Review, Not Bans

Hard bans make teams route around the platform, often to worse places. Instead, a team that needs a key above the limits asks for an exception in a short design review: what the key holds, how it grows, how it is read and deleted, and what happens during resharding. Approved exceptions are recorded with an owner and a review date.

And key design becomes a standard part of service design reviews whenever data grows with users or time, because that is where every big key starts: a list of events per user, a set of followers, a sorted set of all scores.

7Follow-up questions

Who owns cleanup when a retired service leaves a 20 GB key behind?

The team that owned the service, as recorded in the prefix catalogue, owns it until it is cleaned up; retiring a service is not complete until its keys are deleted, which belongs in the decommissioning checklist. If that team no longer exists, ownership passes to whoever took over its domain, and the platform team can do the deletion with UNLINK after a notice period, but the cost stays charged to the owning budget until it is gone.

How do you get 80 teams to adopt the standards?

Start with the data: show each team its own keys in the nightly report, make the limits part of the platform's onboarding and client libraries, and enforce the cheap protections (ACLs, lazyfree) centrally. Most teams fix problems once they can see them.

Would you block writes that exceed the limits automatically?

Not at first. Blocking in production causes incidents of its own. Reports, alerts and reviews come first; hard limits only where the platform must be protected, such as output buffer limits.

8Conclusion

In this answer, we saw that big and hot key incidents come from keys that grow unseen and unowned, so the response combines published limits with reasons and approved patterns, nightly RDB analysis and hot-key signals reported to owners, key prefixes and ACL users that make everything traceable, platform protections such as lazyfree, command restrictions and buffer limits, and exceptions handled through design review rather than bans.

What to say in the interviewAbout 80 seconds aloud

Open with

All three incidents were keys that grew for weeks without anyone seeing or owning them, so I would put four things in place. First, published limits with the reasons: a default maximum of around 1 MB per value and 10,000 elements per key, required TTLs on shared clusters, and approved patterns for large data, meaning split by time or id, page, or store it elsewhere with an index in Redis.

Then, if they want more

Second, automated detection: a nightly offline analysis of RDB snapshots from replicas that reports the largest and fastest-growing keys per prefix to the owning team, plus hot-key signals from LFU sampling or client-side request metrics, especially before promotions.

Third, traceability: every service has its own key prefix in a catalogue and its own ACL user, so every key and command maps to a team.

Fourth, platform protection: lazyfree settings so big deletes and expiries free memory in the background, ACLs that block KEYS, FLUSHALL and MONITOR for applications, client output buffer limits, and a key size check before any resharding. Exceptions go through review instead of bans, and key design is part of every service design review where data grows with users or time.

About this answer

Last updated
13 November 2026
Checked
Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the documentation below. What the checks cover
Where the question comes from
Written by Scrivio for practice. It is not taken from an interview.
Official documentation
Redis documentation
Report an issue with this answer

Copy the line below and send it to the author with what you found. It carries the address of this page.

Issue with "What standards, tooling and ownership would you put in place so big and hot keys are...": https://scrivio-interview-library.netlify.app/databases/redis-internals/0116c27fc5/