Design A Low-Latency Product Price Update API
MicrosoftSoftware Engineer · OnsiteLast updated
Prepare for a read-heavy product pricing system design interview where prices update infrequently but launch-page reads must be low latency. The prompt focuses on versioned price records, caching, bulk reads, invalidation, rollback, and consistency after daily updates.
Design an API and serving system for product prices. Each product price is updated at most once every 24 hours, but the product launch page needs low-latency reads for all products at high traffic.
Constraints & Assumptions
- Reads are much more frequent than writes.
- Each product has at most one price update per day.
- The launch page may request many products at once.
- The system should prioritize low read latency and consistent published prices.
Clarifying Questions to Ask
- How many products are displayed on the launch page?
- Are price updates scheduled or manual?
- Does the page require strong consistency immediately after an update?
- Can prices be precomputed into a page-specific payload?
- What are the traffic and latency targets?
Hints
Hint 1
Hint 1: Start by naming the core entities, constraints, and success criteria.
Hint 2
Hint 2: Make the trade-offs explicit before going deep on implementation details.
Follow-up questions
- How would you support flash-sale overrides?
- How would you roll back a bad price update?
- What cache key would you use for the launch page?
- How would the design change for per-user prices?
Solution walkthrough is for members
Get the full walkthrough with reference code and complexity analysis, plus Kitty Coach at 300 messages a day. Hints, the code runner and community answers stay free.