Skip to main content
Definition Website Computer and Technology

Change Data Capture

Subject: Computer and Technology noun /tʃeɪndʒ ˈdeɪ.tə ˈkæp.tʃər/ 1 definition

  1. Definition (noun)

    Entry #241 · Updated

    Change Data Capture (CDC) is a data integration technique that identifies and captures row-level modifications—such as inserts, updates, and deletes—in a source database and delivers them to downstream systems. Unlike periodic full-table extracts that re-read entire datasets, CDC isolates only the records that have changed since the previous checkpoint, minimizing load on transactional databases while keeping data warehouses, search indexes, caches, and event-driven services synchronized.

    Common Forms

    • Log-Based CDC: Reads the database's native transaction log (such as a write-ahead log or binary log) to capture committed changes asynchronously with minimal impact on source query performance.

    • Trigger-Based CDC: Attaches database triggers to source tables so every insert, update, or delete writes a change record into an audit table, ensuring immediate capture at the cost of added write latency.

    • Query-Based CDC: Polls source tables at scheduled intervals using an indexed timestamp or version column, offering simple deployment without log access while typically missing hard deletes and intermediate updates.

    • Diff-Based CDC: Compares consecutive table snapshots to detect altered records when transaction logs and tracking columns are unavailable, trading high I/O and compute overhead for zero changes to the source schema.

    Example

    An e-commerce team configures a Debezium connector on its primary PostgreSQL database to tail the write-ahead log and stream row-level changes from the orders table to an Apache Kafka topic. Downstream analytics pipelines and an Elasticsearch search index consume those events within seconds, keeping reporting dashboards and storefront inventory current without running heavy analytical queries against the transactional database.