Lesson Overview + Section #01 + RESHADED Checklist + Quiz #1 are unlocked free below (no login required). Unlock all 80 HD video lessons and deep-dive sections — or watch our two free sample video lessons first.
Designing Uber requires architecting a real-time, two-sided geospatial marketplace that matches riders with moving drivers in under 5 seconds, streams live trip telemetry, and settles fares with strict financial accuracy. At global scale—1,000,000 concurrent online drivers reporting GPS coordinates every 4 seconds (250,000 writes/sec) alongside 20,000,000 daily trips—the central architectural challenge is decoupling high-velocity, eventually consistent location telemetry from strongly consistent, durable trip and payment state machines. L4–L6 interviewers evaluate whether candidates avoid spatial-index lock contention on moving points, dispatch using road-graph ETA rather than Euclidean distance, and enforce end-to-end idempotency across external payment gateways.
WHAT YOU WILL MASTER IN THIS LESSON
Partition consistency and durability guarantees by domain: AP in-memory state for 250,000 writes/sec driver coordinates versus CP transactional persistence for trip state transitions and financial ledgers.
Eliminate spatial-index write contention on moving entities by decoupling O(1) in-memory driver hash map updates from periodic quadtree rebuilds or fixed hierarchical hexagonal grids (Uber H3).
Architect low-latency dispatch pipelines combining spatial candidate filtering with directed road-graph ETA evaluation over persistent WebSocket gateways.
Design event-driven fare settlement and sub-50 ms fraud scoring using pre-authorization holds, durable queues, trip_id idempotency keys, append-only double-entry ledgers, and hybrid rule + ML risk engines.
Follow this exact sequence from the Intro narration on every system design prompt so you never miss requirements, math, contracts, or the 13-minute deep dive.
0 / 8 Checked
RRequirements & ScopeMin 2–8
Clarify who the users are, 3–4 core functional flows, explicit non-goals, and target latency/availability SLAs before drawing a single box.
Avoid trap: Still gathering requirements at minute 15 squeezes the deep dive where L5/L6 offers are decided.
EBack-of-the-Envelope MathMin 8–12
Compute ONLY numbers that actively change architectural choices: DAU → peak read/write RPS, daily & 5-year storage, bandwidth (or tokens/sec & KV-cache VRAM for AI).
Avoid trap: Spending 10 minutes multiplying irrelevant byte counts that never influence sharding or caching.
SStorage & Data ModelMin 12–15
Define core tables, primary/partition keys, and access indexes. Separate small structured metadata rows (~1 KB) from bulk binary blobs (S3 + CDN).
Avoid trap: Picking Cassandra or NoSQL by buzzword when 40 writes/s & 3 TB fit cleanly on one indexed SQL primary + replicas.
AAPIs & Wire ContractsMin 15–17
Write 3–4 concrete REST/gRPC/SSE/WebSocket endpoints with request/response shapes, cursor pagination, and Idempotency-Key headers on mutations.
Avoid trap: Hand-waving client-server contracts and discovering missing parameters halfway through the deep dive.
HHigh-Level DesignMin 17–27
Draw the simplest end-to-end working read and write paths first. Every box on the board must trace back to a stated requirement or number.
Avoid trap: Reciting a memorized 12-microservice Kafka mesh before proving why a simpler synchronous path breaks.
DDetailed Design (Deep Dive)Min 27–36
Proactively audit your high-level diagram, name the top 2 bottlenecks (hot partitions, fan-out skew, lock contention, GPU saturation), and go deep on internals.
Avoid trap: Waiting passively for the interviewer to rescue pacing or skimming every box at shallow surface depth.
EEvaluation & Failure ModesMin 36–41
State what each architectural choice COSTS you, and trace graceful degradation when cache, queue, external vendor, or primary DB fails.
Avoid trap: Assuming happy-path uptime or placing slow 3-second external calls inline on revenue-critical write paths.
DDistinctive FeatureMin 41–45
Solve the signature hard problem unique to this prompt (e.g., double-entry ledger idempotency, Geohash dispatch locks, OT/CRDT sync, or SSE token streaming).
Avoid trap: Spending 20 minutes on generic login/CRUD tables and zero time on the core distributed challenge.
INTERVIEWER SCORECARD · WHAT MAKES A STRONG HIRE?
5 Signals Bar Raisers Grade (L4 vs. L5 Senior vs. L6 Staff)
Senior (L5 / E5 / Senior SDE) Bar — Autonomous Pacing, Depth & Proactive Trade-Offs: Owns the 45-minute clock without prompting, derives every component quantitatively, surfaces failure modes (hot shards, stampedes, dual writes) BEFORE being asked, and defends consistency vs. latency trade-offs.
1. Scoping
✓ STRONG HIRE SIGNAL
Clarifies users, read/write skew, p99 latency, consistency bounds, and explicit non-goals in minutes 2–8.
✗ NO-HIRE RED FLAG
Jumps straight into drawing load balancers and microservices at minute 2 without asking a single question.
2. Right-Sized Design
✓ STRONG HIRE SIGNAL
Starts with the simplest working architecture justified by the math (e.g., 1 NVMe SQL primary + replicas + Redis for 40 writes/s & 3 TB).
✗ NO-HIRE RED FLAG
Recites a memorized Kafka + multi-DC Cassandra diagram that contradicts their own traffic calculations.
3. Technical Depth
✓ STRONG HIRE SIGNAL
Drives deep into 1–2 hard bottlenecks (partition keys, hot-key mitigation, transactional outbox, KV-cache batching) at minute 27.
✗ NO-HIRE RED FLAG
Skims across 12 boxes at identical buzzword depth and runs out of time before the deep dive.
4. Explicit Trade-Offs
✓ STRONG HIRE SIGNAL
Uses 3-part reasoning: 'A queue here because SMTP spikes to 3 s; checkout stays <60 ms, and we accept eventual email delay + retry dedup.'
✗ NO-HIRE RED FLAG
Name-drops tools ('We put Kafka and ZooKeeper here') without stating the alternative or operational cost.
5. Communication
✓ STRONG HIRE SIGNAL
Thinks aloud every 30–45s, checks alignment at phase transitions, and treats 'What if X fails?' as a cue for where points are awarded.
✗ NO-HIRE RED FLAG
Goes silent for 5 minutes while drawing or defends a flawed assumption defensively when nudged.
ARCHITECTURE & DATA-FLOW SLIDES · SLIDE 1 OF 1Section 01: System Design: Uber
ARCHITECTURE / DATA FLOW DIAGRAM
SECTION 01 OF 6
1. System Design: Uber
★ FREE PREVIEW
Key Takeaway: Uber combines a write-dominated geospatial index over continuously moving drivers with an ACID trip workflow and an exactly-once payment settlement pipeline.
ARCHITECTURE / DATA FLOW DIAGRAM
Two-Sided Marketplace Mechanics
Uber coordinates riders and drivers across physical road networks in real time. Online drivers run a foreground client that transmits GPS coordinates to backend ingestion gateways every 4 s. When a rider opens the application, views nearby vehicles, and requests a ride from pickup to dropoff, the platform queries nearby available drivers, computes road-network arrival times, and dispatches an exclusive offer to the optimal candidate. Once the driver accepts, both clients track the vehicle's live trajectory until dropoff, triggering automated fare capture and bidirectional ratings.
Continuous Supply Telemetry: Every active driver emits (driver_id, lat, lng, timestamp) every 4 s, making write ingestion the highest-QPS path in the platform.
Time-Bounded Dispatch: Matching must complete within 3–5 s; riders forced to wait 30 s experience steep cancellation and churn rates.
Financial Atomicity: Every completed ride triggers real-world money movement across riders, drivers, and platform fees, tolerating zero lost or duplicate charges.
Candidates frequently attempt to reuse a static proximity architecture (such as Yelp or Google Places) where point-of-interest coordinates are indexed once in a read-optimized PostgreSQL PostGIS or R-tree cluster and cached heavily. That pattern collapses under ride-hailing workloads because 1,000,000 moving vehicles invalidate their coordinates every 4 s, turning read-optimized spatial trees into lock-contended write bottlenecks. Furthermore, static directory lookups are stateless reads, whereas a ride request initiates a stateful, multi-step workflow spanning exclusivity locks, driver timeouts, live streaming, and payment settlement.
Architectural Dimension
Static Proximity Service (Yelp)
Dynamic Ride-Hailing (Uber)
Engineering Consequence
Entity Coordinates
Stationary venues; updated rarely (days/months)
Moving vehicles; updated every 4 s per online driver
Cannot mutate disk-backed B-trees or R-trees synchronously on every ping
Read-to-Write Ratio
Read-dominated (100:1 reads to writes)
Write-dominated (250,000 GPS writes/sec vs. 230 trip requests/sec)
Ingestion path must use persistent sockets and lock-free O(1) in-memory overwrites
Distance Metric
Radial Haversine distance (lat/lng bounding box)
Directed road-network travel time (ETA) with live traffic
Spatial index narrows candidates; road-graph ETA service makes final rank
State & Consistency
Stateless search queries; eventual consistency throughout
Multi-state trip lifecycle + real money settlement
Split architecture: AP memory tier for GPS, CP transactional DB + ledger for trips
Interview Signal: Interviewer Signal: Explicitly contrasting stationary spatial indexing (read-heavy disk trees) against high-frequency moving-point indexing (write-heavy in-memory state) in the opening 2 minutes immediately establishes Staff-level problem framing.
SECTION 02 OF 6
2. Requirements of Uber's Design
🔒 PRO SECTION
Key Takeaway: Enforce strict transactional durability and consistency for trip states and payments, while relaxing consistency to a 4-second staleness bound for 250,000 writes/sec of ephemeral driver coordinates.
Section 1 + Checkpoint Quiz #1 are unlocked free outside the paywall. Unlock all architecture slides, QPS & sharding trade-off tables, and all 80 narrated HD video lessons with Full Access — or inspect our sample payment system lesson first.
Key Takeaway: Persistent WebSocket gateways terminate 250,000/sec driver heartbeats into city-sharded in-memory location stores, while a transactional Trip Service coordinates candidate ranking across Spatial Index and road-graph ETA services.
Section 1 + Checkpoint Quiz #1 are unlocked free outside the paywall. Unlock all architecture slides, QPS & sharding trade-off tables, and all 80 narrated HD video lessons with Full Access — or inspect our sample payment system lesson first.
Key Takeaway: Absorb 250,000/sec location writes in an O(1) hash map decoupled from spatial-index structure updates, push active trip telemetry via ephemeral pub/sub topics, and map each entity to a purpose-built storage engine.
Section 1 + Checkpoint Quiz #1 are unlocked free outside the paywall. Unlock all architecture slides, QPS & sharding trade-off tables, and all 80 narrated HD video lessons with Full Access — or inspect our sample payment system lesson first.
5. Payment Service and Fraud Detection in Uber Design
🔒 PRO SECTION
Key Takeaway: Decouple fare capture through durable event queues, guarantee exactly-once charging with trip_id idempotency keys and an append-only double-entry ledger, and block fraud via sub-50 ms inline risk scoring plus post-trip route audits.
Section 1 + Checkpoint Quiz #1 are unlocked free outside the paywall. Unlock all architecture slides, QPS & sharding trade-off tables, and all 80 narrated HD video lessons with Full Access — or inspect our sample payment system lesson first.
Key Takeaway: In-memory location state self-heals within a single 4-second reporting cycle after crashes, while city-sharded stateless services, write-ahead SQL persistence, and idempotent payment queues guarantee zero lost trips or duplicate charges.
Section 1 + Checkpoint Quiz #1 are unlocked free outside the paywall. Unlock all architecture slides, QPS & sharding trade-off tables, and all 80 narrated HD video lessons with Full Access — or inspect our sample payment system lesson first.