Operating Postgres Logical Replication at Massive Scale
summary
ClickHouse runs Postgres logical decoding as a production CDC pipeline moving ~300–350 TB of CDC data per month (350B+ rows) for 300+ customers, with individual Postgres DBs up to ~60 TB. The system uses Temporal workflows, Kubernetes pods, S3 staging, and a stateless flow worker design that decouples reads and writes; it implements parallel CTID snapshotting and always-on replication slots to avoid WAL bloat. PureDB (OSS) and ClickPipes (managed) power the deployment; it works in production but still handles schema-change gaps, slot-growth and single-thread decoding limits.
AI-written summary · about
chapters (10)
- 0:00Introduction and speaker background
- 3:35Postgres CDC and logical replication primer
- 9:58Postgres to ClickHouse replication at scale
- 16:21Architecture for massive scale replication
- 27:34Key design decisions and optimizations
- 33:48Obsessing over user experience
- 38:20Big gaps and future roadmap
- 40:26ClickHouse managed Postgres service
- 41:10Live demo and state machine walkthrough
- 46:25Q&A and closing remarks
related talks
27mBuilding a PostgreSQL data warehouse
42mClickHouse: what is behind the fastest columnar database
34mClickHouse® - What is Behind the Fastest Columnar Database?
38mA journey into postgresql logical replication
55mBuilding Fast ClickHouse Analytics for MySQL Transaction Data Using Kubernetes
17mBuilding Real-Time Data Lake with ClickHouse
28mColumnstore Revolution
38mPostgreSQL as a distributed computing platform
