Change Data Capture
ELI5 — The Vibe Check
Change Data Capture (CDC) watches your database for changes and streams them as events. Every INSERT, UPDATE, DELETE becomes a message that other systems can consume. It's like a security camera for your database — everything that changes gets recorded and broadcast.
Real Talk
Change Data Capture is a design pattern that identifies and captures changes to data in a database and delivers them as events to downstream systems. CDC reads the database's transaction log (WAL in Postgres, binlog in MySQL) to detect changes without impacting database performance. Tools like Debezium, Maxwell, and AWS DMS implement CDC for real-time data synchronization.
When You'll Hear This
"We use Debezium CDC to stream database changes to Kafka in real-time." / "CDC eliminated our nightly ETL batch job — data syncs in milliseconds now."
Related Terms
Event-Driven Architecture
Event-Driven Architecture is like a gossip network. When something happens (order placed!), it broadcasts the news.
Outbox Pattern
The outbox pattern solves the dual-write problem: how do you update a database AND send a message to a queue atomically?
Write-Ahead Log
The Write-Ahead Log (WAL) is the database's diary. Before changing any actual data, the database first writes what it's about to do in this log.