SYSTEM Cited by 1 source
ProxySQL¶
ProxySQL is an open-source high-performance proxy for MySQL (and MySQL-protocol-compatible servers like MariaDB), written in C++. It sits between the application and the database fleet, speaking the MySQL wire protocol on both sides, and provides connection pooling, query routing (by user / query pattern / read-write split), caching, and fleet-level failover. Official site: proxysql.com.
Position in the sharding landscape¶
Justin Gage's 2023 framing (Source: sources/2026-04-21-planetscale-what-is-database-sharding-and-how-does-it-work):
"ProxySQL isn't a full fledged solution for [shard routing], but it could be classified as a rough 'shard routing' service."
The framing is precise: ProxySQL is not a sharding substrate — it doesn't understand logical shards, cross-shard queries, resharding, or distributed transactions. But it is a routing primitive that teams can compose into a shard-routing solution by configuring its rule engine to match on schema_name / database / query patterns and dispatch to different backend hostgroups. That's enough for operator-authored shard routing when the application has already bucketed writes by shard key before issuing the query.
What ProxySQL provides¶
- Connection pooling — reuses connections to backend MySQL instances, multiplexing many application connections onto a smaller pool of backend connections.
- Read/write split routing — rule-based dispatch of
SELECTqueries to replicas and writes to primaries. - Query routing by pattern — regex-based rules that match query text and send matches to named hostgroups.
- Query caching — transparent cache of
SELECTresults keyed by query text. - Query rewriting — before-dispatch rewrites for shim-layer compatibility.
- Hostgroup failover — primary-replica topology awareness and failover without the application noticing.
Distinct from Vitess¶
- Vitess is a sharding substrate: it owns the shard-key → shard mapping, splits queries across shards, aggregates results, and orchestrates online resharding. The application sees what looks like one logical table.
- ProxySQL is a routing primitive: it forwards queries to hostgroups based on rules. Shard-key semantics are the application's responsibility; ProxySQL just routes what it receives.
Teams building from scratch on top of MySQL sometimes use ProxySQL + application-layer shard routing as a lightweight alternative to Vitess — the application hashes the shard key and chooses which ProxySQL-fronted hostgroup to query. This is the pre-Vitess-era application-level sharding pattern in modern dress.
Wiki scope¶
This is a stub. For ProxySQL-specific material consult the official ProxySQL docs + René Cannaò's blog (the project maintainer).
Seen in¶
- sources/2026-04-21-planetscale-what-is-database-sharding-and-how-does-it-work — Justin Gage (guest post for PlanetScale, 2023-04-06) names ProxySQL as "a rough 'shard routing' service" in the context of teams building operational-maintenance primitives for application-level sharding. First wiki disclosure of ProxySQL as a routing substrate adjacent to but distinct from Vitess.