Mock Interviewer
Ask Coach
Tap a question to start, or type your own below.
Key-Value Store System Design
Visual Problem Diagram

Scenario
You save a session under one key and expect the read to come back in under 10 milliseconds, even after a machine dies, because other machines hold copies. The painful failure is when one slice of keys takes 20% of all traffic and those reads crawl, because that slice lives on a single machine while the others sit idle.
Clarify this problem here, or open Pathway Coach if you want a prep plan first.
You can save a value under a key. You can read it back. You can delete it. You can ask for a value to expire. The store keeps copies on other machines so one dead machine does not lose the value.
You need to explain how keys are spread so adding a machine does not move every key. You need to explain how many copies must say yes before a write or a read succeeds. You need to explain what a read returns when two copies disagree. You need to explain where a key is served when its machine is down. You need to explain what you do when one slice of keys gets a huge share of traffic. Transactions that touch many keys can stay thin.
Constraints
Read, save, or delete a value by key. Optionally expire a key. Keep several copies. Let a caller choose how many copies must agree.
The store stays up about 99.99% of the time. Most warm reads finish in under 10 milliseconds, so a lookup feels instant. It keeps serving when a machine dies or the network splits.
Petabytes of data and billions of keys across 100 or more machines. The hot action is a read or a write by key. Millions of those operations a second dominate, and one slice of keys can take about 20% of them.
Stages ahead
Not ready to design yet?
Try the free Coach trial — ask how to prep, what to practice first, or how InterviewCrafted works. Sign in when you want to start this problem.
Log in to start practicing
Preview the problem below. Sign in to start your timed session, save progress, and use the AI coach.
Want full access now? View Pro pricing