System Design HLD-18.04
Deep dives and trade-off discussions
Picking the component most likely to break, laying out two real options, choosing with reasons tied to requirements, and quantifying with your estimates.
The big idea
A high-level diagram shows you know the building blocks; a deep dive shows you understand them. In a deep dive you take one component, usually the one most likely to break under the requirements, and examine it properly: what can go wrong, which designs could work, what each costs, and which you choose and why. This is where most of the signal in a design interview comes from, and where real design reviews earn their keep.
The key skill is trade-off reasoning. There is rarely a single right answer, but there are well-reasoned and poorly reasoned choices. "I'd use fan-out on write because reads outnumber writes 100 to 1 and feeds must load in 200 ms, except for accounts with millions of followers, where I'd switch to fan-out on read" is a strong answer even if the interviewer would have chosen differently.
Think of a mechanic inspecting a used car. Glancing at every part tells you little; testing the brakes and the engine properly, the parts most likely to fail and most expensive if they do, tells you whether to buy.
How it works
Step 1: Pick the riskiest component
Look for the place where the requirements and estimates collide: the hottest data, the highest write rate, the strictest consistency need, the biggest fan-out. For a news feed it is feed generation; for a chat system, delivery and ordering; for a payment system, exactly-once charging; for a URL shortener, unique short codes and redirect latency. Say why you picked it.
Step 2: Two options, then a choice
- State the problem in terms of the requirements: "200,000 feed reads per second with p99 under 200 ms, while a celebrity post reaches 50 million followers."
- Present two real options, each with its strengths and costs.
- Quantify with your estimates: "fanning out one celebrity post means 50 million cache writes; at 100,000 writes per second that is over 8 minutes of work".
- Choose, tie the choice to the requirements, and name what you are giving up.
- Name the failure mode of your choice and how you would detect and handle it.
Try it
Going deeper
Let the interviewer steer
Offer the choice: "the two riskiest parts are feed generation and media storage; which would you like me to go deep on?" It shows you see both, and lets the interviewer test what they care about. If they push back on your choice, treat it as information, not an attack: re-examine with the new constraint.
Trade-offs
| Option | Wins when | Loses when |
|---|---|---|
| One deep dive done well | Showing real understanding with time to quantify | Breadth across other components |
| Several shallow dives | Showing awareness of many risks | Depth: few concrete numbers or failure modes |
Common mistakes
- Diving into the easiest component instead of the riskiest.
- Presenting one option as the only answer.
- Choosing without referring to the requirements or numbers.
- Never mentioning how the chosen design fails.
Check yourself
-
Which component deserves the deep dive?
Show answer
B. The one most likely to break given the requirements and estimates Depth on the riskiest part shows you can handle real pressure points.
-
What makes a trade-off choice convincing?
Show answer
B. Tying it to requirements and quantifying with estimates Reasons grounded in the problem make a choice defensible.
-
How many characters of base62 are needed for 100 million links a month for decades?
Show answer
C. 7 62^7 is about 3.5 trillion, enough for thousands of years at that rate.
-
The interviewer disagrees with your choice. What is the best response?
Show answer
B. Re-examine it with their new constraint and adjust if needed Pushback is information; reasoning openly with it is what they want to see.
Recap
- Deep dives show understanding; pick the component most likely to break.
- Lay out two real options with their strengths and costs.
- Quantify with your earlier estimates.
- Choose, tie it to requirements, and name what you give up.
- Describe how your choice fails and how you would notice.
Next up
- Crack the system design round learning path