API Gateway: Low-Level Design
An API gateway is the single entry point for all client requests in a microservices architecture. It sits in front […]
An API gateway is the single entry point for all client requests in a microservices architecture. It sits in front […]
Collaborative document editing allows multiple users to edit the same document simultaneously, with changes from all users appearing in real
A typeahead (autocomplete) service returns ranked completions for a query prefix in under 100ms. Google Search completes queries as you
A live leaderboard ranks users by score in real time — ranking millions of players by score in a game,
A session management system maintains state across stateless HTTP requests — tracking who a user is across page loads without
An ad click tracking system records every click on an advertisement, deduplicates fraudulent clicks, aggregates counts for billing, and provides
A shopping cart stores a user’s intended purchases before checkout. The design must handle: anonymous users (no account), authenticated users
A distributed task queue decouples work from workers: producers enqueue tasks, workers consume and execute them asynchronously. This enables horizontal
A key-value store is the simplest form of a database: store a value associated with a key, retrieve the value
A ride-sharing platform (Uber, Lyft) matches riders with nearby drivers in real time, handles surge pricing, tracks vehicle positions, and
A ticketing system (like Ticketmaster for concerts, or an airline seat booking system) manages limited inventory under simultaneous high demand.
A recommendation system suggests relevant items to users — products to buy, videos to watch, friends to follow. At Netflix,
A payments system processes financial transactions — charge customers, transfer funds, process refunds. Unlike typical web applications, payments demand ACID
A social network feed aggregates posts from accounts a user follows, ranked by relevance or recency. At Instagram or Twitter
A video streaming platform (like Netflix or YouTube) must ingest raw video, encode it into multiple quality levels, distribute it