Preventing App Performance Degradation Due to Sudden Ride Demand Spikes
Article Summary
Grab's engineering team faced a brutal problem: rain in Southeast Asia would crash their entire ride-hailing system. When demand spiked locally, users everywhere suffered.
Grab's engineers built the 'Spampede' filter, a circuit breaker inspired solution that prevents localized demand spikes from degrading app performance globally. The system intelligently throttles requests when supply can't meet demand in specific geographic areas.
Key Takeaways
- Uses Geohash algorithm to bucket locations without expensive API calls
- Redis INCR tracks unallocated requests with automatic TTL cleanup
- Intentionally drops bookings to protect system-wide availability
- Trades monitoring accuracy for throughput using time bucketing
- Processes requests before hitting downstream services to minimize load
Critical Insight
By strategically rejecting requests in oversaturated areas, Grab prevented localized demand spikes from taking down their entire platform.