Design Uber
HardSystem design · Geospatial Realtime · Uber
Design Uber: riders request a trip, drivers stream their location, the system matches a nearby driver, and the trip moves through pickup, ride and payment. Focus on the driver location index, batched matching and offer races, the trip state machine on unreliable clients, regional partitioning and live tracking. Fare computation is covered by the ride pricing problem and is treated as a service here. Out of scope: maps/routing internals and driver onboarding.
Requirements
- Ingest high-volume location updates into an in-memory geospatial index of available drivers
- Match by ETA over road distance, in short batches, with atomic leased offers
- Model the trip as an idempotent state machine with cancellation rules and reconnect recovery
- Partition by city/region; quote a locked fare, deliver live position to the rider, and settle payment on completion