Lesson 7 of 19
2. Back-of-Envelope Estimation

2.6 Why does the read/write ratio matter?

3 min read+10 XP

At the wedding: Each dish is cooked once but served hundreds of times. Cooking and serving are different jobs, so you staff them differently: a few cooks, many servers at the counter.

In the system: Reads (viewing) and writes (creating or changing) stress different parts of a system. Estimate both.

For PicShare (assumed): 2 million photo uploads a day.

  • Writes ≈ 2 million ÷ 86,400 ≈ 23 a second.
  • Reads ≈ 5,800 a second.
  • Ratio = 500 million ÷ 2 million = 250 reads for every write.

What the ratio tells you:

ShapeExamplesIt points you to
Read-heavyPhoto feeds, product pages, URL shortenersCaches, read replicas, CDNs: make copies
Write-heavyLogs and metrics, chat messages, location updatesQueues, sharding, append-friendly storage: spread the writes
BalancedCollaborative docs, some gamesBoth, chosen per feature

Memory code: "Read-heavy? Copy it. Write-heavy? Spread it."