Skip to content

carakawedhatama/go-cdc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

go-cdc

This repository demonstrates how to use Change Data Capture (CDC) with Debezium, Kafka, and Go. Inspired by this video, thanks to Eko Kurniawan Khannedy 🎉.

Prerequisites

  • Docker
  • Docker Compose
  • Go

Setup

  1. Clone this repository:

    git clone https://github.com/carakawedhatama/go-cdc.git
    cd go-cdc
  2. Start the services using Docker Compose:

    docker-compose up -d
  3. Run the Go application:

    go mod tidy
    go run main.go

How it works?

  • MariaDB is set up with a sample database and table.
  • Debezium captures changes from the MariaDB transaction log and sends them to Kafka.
  • The Go-CDC application consumes the changes from the Kafka topic and prints them.

License

This project is licensed under the MIT License.

Releases

No releases published

Packages

No packages published

Languages