ProxySQL at Scale
summary
Pinterest runs ProxySQL pools for 100+ backend types and 400+ EC2 instances and automates provisioning with Terraform modules, Puppet for bootstrapping, and Python proxy manager. The system uses NLB + autoscaling groups, EFS for persistent logs, TCP health checks on 3306, and a terraform-driven zero‑downtime blue/green ASG migration pattern plus occasional AWS instance refresh. Tests run by spinning real infra via pytest and a terraform-ci library, exercising apply/validate/destroy to catch drift and verify no traffic errors.
AI-written summary · about
chapters (20)
- 0:00Intro
- 0:34Challenges
- 6:32Three level provisioning
- 8:56Guiding principles
- 13:23ProxySQL Unit
- 17:42Example: Terraform
- 22:23What module creates
- 24:07Healthchecks
- 34:23Zero downtime migration: Step 1
- 38:14Zero downtime migrations: How to test
- 39:26Testing a module: terraform-ci
- 43:38Bootstrapping instance
- 47:34Puppet: what to run?!
- 47:51Example: Puppet
- 48:56Bootstrap ProxySQL configuration
- 49:24ProxySQL Manager logs
- 51:02Arch & Workflow (GitOps)
- 51:39Data model
- 51:56ProxySQL configuration constraints
- 52:36Source of Truth(s)
related talks
55mProxySQL Use Case Scenarios
37mScale MySQL beyond limits with ProxySQL
24mPinterest’s Exploration of Distributed SQL
50m#ProxySQL Use Case Scenarios
41mProxySQL 2021 Dev Submit
27mThe State of ProxySQL, 2020 Edition
55mProduction with ProxySQL and Orchestrator
46mBig databases, many servers, data center or cloud - it's all here!
