Traffic Modeling
1 min read
Map read/write ratios and access patterns to identify which operations dominate.
Characterize read/write ratios and access patterns before choosing technologies. Skewed reads demand caching; balanced I/O demands write optimization.
How It Works
Traffic modeling characterizes your workload before you design for it. Key questions: What is the read/write ratio? (100
reads -> Caching-heavy design; 1 -> write-optimized). Are reads uniform or skewed? (Zipfian distribution -> hot keys). Is traffic steady or bursty? In interviews, stating the traffic model before choosing technologies shows you design from data.Real-World Example
Instagram's traffic model: reads are extremely skewed — 1% of posts generate 80% of reads. This Zipfian distribution drives aggressive CDN caching for popular content with a feed fan-out model that pre-computes timelines for celebrity followers.
Test Yourself
Scenario: A food delivery app has 20M daily active users. The average user opens the app 4 times per day, and each session triggers 5 API calls. The read-to-write ratio is 10:1, and peak traffic is 3x the average. Model the traffic.
Get notified when we launch
One email when the full practice product is live. No spam.