All guide activities

CH-11 · CHAPTER REVIEW

Worked interview distributed cache

Solve these two questions after studying the chapter. State your assumptions and explain your reasoning.

Read. Try. Defend.

Companion to the Buildfest System Design guides.

Chapter review: two questions

Attempt both questions before opening the model answers.

Question 1

Twenty million entries each use a 500-byte value and a 100-byte key. Estimate raw bytes with one extra full copy; name two costs excluded from that estimate.

Reveal model answer

Raw key-plus-value data is 20,000,000 x 600 bytes = 12 GB. One additional full copy gives 24 GB using decimal units. Allocator/entry metadata, routing structures, safety margin and network traffic are excluded. Exact provisioning needs implementation measurements.

Question 2

A cache node fails and source reads jump toward the full request rate. Explain three controls and the freshness/availability choice you would expose to the product.

Reveal model answer

Use per-key fetch coalescing, bounded source concurrency/admission and gradual warm-up; suitable replica/local copies may also help. Define whether stale descriptions can be served or reads should fail under pressure. Never silently apply that stale policy to authorization or balances.

Answers stay in this tab. Download before leaving. This practice is not graded or saved to your account.