# Shard Balancing: Moving Shops Confidently with Zero-Downtime at Terabyte-scale

DevFeed: [Shard Balancing: Moving Shops Confidently with Zero-Downtime at Terabyte-scale](<https://devfeed.tech/articles/shard-balancing-moving-shops-confidently-with-zero-downtime-at-terabyte-scale-1504.md>)

Original publisher: [Read original article](<https://shopify.engineering/mysql-database-shard-balancing-terabyte-scale>)

Author: Paarth Madan

Published: 2021-09-24T20:41:32Z

Content type: article

Language: en

Sources: [Shopify Engineering](<https://devfeed.tech/sources/shopify-engineering.md>), [Shopify Engineering - Shopify Engineering](<https://devfeed.tech/sources/shopify-engineering-shopify-engineering.md>)

Topics: [MySQL](<https://devfeed.tech/topics/mysql.md>), [Shopify](<https://devfeed.tech/topics/shopify.md>), [Database](<https://devfeed.tech/topics/database.md>), [systems](<https://devfeed.tech/topics/systems.md>), [Routing (disambiguation)](<https://devfeed.tech/topics/routing.md>)

Tags: [architecture](<https://devfeed.tech/tags/architecture.md>), [database](<https://devfeed.tech/tags/database.md>), [infrastructure](<https://devfeed.tech/tags/infrastructure.md>), [load-balancer](<https://devfeed.tech/tags/load-balancer.md>), [mysql](<https://devfeed.tech/tags/mysql.md>), [routing](<https://devfeed.tech/tags/routing.md>), [scale](<https://devfeed.tech/tags/scale.md>), [shopify](<https://devfeed.tech/tags/shopify.md>), [systems](<https://devfeed.tech/tags/systems.md>)

## AI overview

Shopify describes how it balances MySQL database shards by moving shops between shards online with virtually zero consumer-facing downtime. The article explains Shopify's podded application architecture, routing through a load balancer, and the operational need to redistribute resource-intensive shops so database utilization remains balanced and infrastructure risk is reduced.

## Source excerpt

Moving a shop from one shard to another requires engineering solutions around large, interconnected systems. The flexibility to move shops from shard to shard allows Shopify to provide a stable, well-balanced infrastructure for our merchants. With merchants creating their livelihood on the platform, it's more important than ever that Shopify remains a sturdy backbone. High-confidence shard rebalancing is simply one of the ways we can do this.