Scenario
A shop's product pages each call a product API, which reads the product — name, description, price, stock — from a SQL database. At lunchtime that is 2,000 page loads a second, almost all of them for the same few hundred popular products. A product's price or stock changes a few times a day. Today the database sits at 90% CPU at lunchtime and pages take 800 ms.
Requirements
Constraints
- two engineers, no dedicated ops
- one region
- the SQL database stays the only source of truth for price and stock
Hints