All Questions
Caching medium

You cache 50,000 product prices with a strict TTL of 1 hour. At 12:00 PM, you restart the app, populating the cache. At 1:00 PM, the database spikes to 100% CPU. Why, and how do you fix it?

  1. A This is a 'Thundering Herd' event caused by parallel computation; fix it by implementing Request Coalescing at the application layer.
  2. B This is a 'Cache Avalanche' caused by synchronized expirations; fix it by adding a random time jitter to the TTL during cache population.
  3. C This is a 'Hot Key' contention issue on the distribution ring; fix it by migrating the frequently accessed shards to localized L1 memory.
  4. D This is a 'Network Partition' causing the cache cluster to diverge; fix it by deploying a Circuit Breaker to fail-fast during the rollout.

One system design question a day, with spaced repetition so the ones you miss come back.

Get the app

Related questions