Scalability Patterns and Techniques Questions

Scaling a system to handle growth in traffic and data: horizontal versus vertical scaling, statelessness, sharding and partitioning strategies, read replicas, and connection pooling. Covers capacity estimation, identifying bottlenecks, and the tradeoffs each scaling axis introduces. The general toolkit for taking a design from thousands to millions of users.

MediumSystem Design
35 practiced

Design a caching layer for a product-details API that must sustain 10,000 requests per second with a P95 latency target of 50ms. Cover your cache topology (edge CDN, application-level, distributed cache), eviction policy, TTL strategy, how you'd guard against cache stampede, cold-start handling, and the instrumentation you'd add to measure effectiveness.

MediumTechnical
44 practiced

Design connection-pool management for a microservice that serves 500 concurrent request handlers and makes both database and upstream HTTP calls. How would you size the DB connection pool versus the HTTP client pool, choose timeouts and max lifetimes, integrate with circuit breakers, and test pool behavior under a simulated production spike?

EasyTechnical
27 practiced

A product expects 1,000,000 active users per day, with the average session generating 20 API requests. Estimate the expected peak requests-per-second, assuming 10% of daily traffic occurs in the busiest hour. Show your calculations, state your assumptions about traffic shape, and explain how a different busiest-hour fraction would change the result.

MediumTechnical
26 practiced

Your service is stateful and stores per-user ephemeral session data in memory. Walk through three practical approaches to scale it horizontally without breaking correctness: sticky sessions, active-active replication, and externalizing the state. For each, describe the operational complexity, failure modes, and performance characteristics.

HardTechnical
26 practiced

A hot cache entry is about to expire, or a backend service is recovering from an outage, and you expect a flood of simultaneous requests to hit the same key or the same origin at once. Design a comprehensive strategy to prevent this 'thundering herd' across a globally distributed cache and service fleet, covering both techniques that stop the herd from forming in the first place and techniques that contain it once it starts. What would you monitor and alert on to confirm the mitigation is working, and what trade-off would you make between complexity and protection?

Unlock Full Question Bank

Get access to all Scalability Patterns and Techniques interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.