Cut checkout API p99 latency by 80% under peak load
Under campaign traffic the checkout API degraded badly — p99 hit ~900ms, timeouts spiked, and customers were abandoning carts at the last step. I profiled the hot path instead of guessing, moved read-heavy lookups behind a write-through cache with event-driven invalidation, and added a covering index for the worst query. Each change shipped behind a flag with the old path one toggle away.
p99 dropped from ~900ms to ~180ms; timeout rate fell below 0.1% — an 80% reduction sustained at 3x prior peak throughput.