Shopify replaced Redis with MySQL for inventory reservations – and it scaled

Shopify replaced Redis with MySQL for inventory reservations–and it scaled

Shopify replaced Redis with MySQL for inventory reservations – and it scaled

Shopify rebuilt its oversell protection system on MySQL, using one row per inventory unit and the SKIP LOCKED feature to handle peak traffic. The move eliminated consistency issues between Redis and the inventory ledger. The real bottleneck wasn't CPU or slow queries, but connection exhaustion caused by other parts of the checkout path holding database connections too long. After tagging queries and cleaning up the checkout flow, they removed 50% of reads and 33% of transactions on the primary database, meeting their high-throughput targets.

The cleanup of the checkout path removed 50% of reads and 33% of transactions on the primary database.

More from this day

2026-08-09