RELIABILITY, SECURITY & CASE STUDIES · SUBTOPIC
Driver Matching, Dispatch & Live ETA
Stream 4-second GPS pings, lock a driver atomically during offer dispatch, and compute road-network ETAs.
AdvancedPart of Geo-Spatial & Location Systems
Subtopics in Geo-Spatial & Location Systems (2)
In plain words
Drivers ping their GPS every 4 seconds into fast RAM. When you tap "Request Ride", the matcher picks the closest cars by road ETA (not just straight-line crow-flies) and locks one driver for 15 seconds so two riders don’t get the same car.
Think of it like…
Air-traffic radar updating every few seconds + holding a cab on a 15-second reservation while the driver taps Accept.
Loading interactive diagram
Loading interactive exercise
Theory & how it works
Straight-line (Haversine) distance vs. Road-Network ETA
A driver 300 meters away across a river or highway median might actually be a 12-minute drive! First filter candidates quickly in Redis using H3/Geohash (~20 nearby drivers), then pass only those 20 to a fast Routing / Contraction Hierarchies ETA engine using live traffic speeds.
Key points & practical guide
Summary checklist
- Keep live GPS pings in RAM (Redis) with 30s TTL; archive trip breadcrumbs asynchronously to Kafka/warehouse
- Use short 15s distributed locks per candidate driver during dispatch
- Filter with spatial grid first, then rank top candidates by real road ETA
When to use it
- Uber/Lyft dispatch, DoorDash/Instacart courier matching
Watch out for
- Offering the same driver simultaneously to 3 riders at peak hour
Quick check
Loading quiz