System Design Patterns: From Fundamentals to Real Systems
0% completed
Write-Behind
1. The Incident
The product team requests a small feature: every product page should display a counter such as "12,483 people viewed this today." The direct implementation runs UPDATE products SET views = views + 1 for every page view.
During peak traffic, the bestseller receives 12,000 views per second and therefore causes 12,000 UPDATE operations against one row. Because a database protects a row during modification with a lock, those operations form a queue in which each request waits for its predecessor.
.....
.....
.....
Like the course? Get enrolled and start learning!
Reading Progress
0%