All systems

Viral feed.

Opening a social app shows a timeline: the newest posts from everyone you follow. Build it at read time, then at write time, then watch one celebrity post break it.

The simple way: build each timeline when someone opens the app. That is 20 queries per read, one after another, so reads are slow. Push readers past 5,000 and the posts database overloads. A cache buys you more room, but the work still grows with every reader.

Readers2,000 online0 req/sTimeline API0 reads/s20 queries per readPosts cacheOffPosts databaseConns 0/5000 queries/sTimeline cacheLevel 2New postsLevel 2Fan-out queueLevel 2Fan-out workersLevel 2
  • Request
  • Request that will fail
  • Thicker line, more traffic
Clock
0:00
Requests
0/s
p95 latency
–
Errors
0%
Cost
$0.00/h

Click any box

Each box explains what it does and how it fails.

Event log

Nothing has broken yet. Crashes, limits and scaling show up here.

Next systemPayments