ScyllaDB University LIVE, FREE Virtual Training Event | March 21
Register for Free
ScyllaDB Documentation Logo Documentation
  • Server
  • Cloud
  • Tools
    • ScyllaDB Manager
    • ScyllaDB Monitoring Stack
    • ScyllaDB Operator
  • Drivers
    • CQL Drivers
    • DynamoDB Drivers
  • Resources
    • ScyllaDB University
    • Community Forum
    • Tutorials
Download
ScyllaDB Docs ScyllaDB Open Source Getting Started ScyllaDB Integrations and Connectors Integrate ScyllaDB with Kafka ScyllaDB CDC Source Connector ScyllaDB CDC Source Connector Quickstart

Caution

You're viewing documentation for a previous version. Switch to the latest stable version.

ScyllaDB CDC Source Connector Quickstart¶

Synopsis¶

This quickstart will show you how to setup the ScyllaDB CDC Source Connector to replicate changes made in a ScyllaDB table using ScyllaDB CDC.

ScyllaDB setup¶

First, let’s setup a ScyllaDB cluster and create a CDC-enabled table.

ScyllaDB installation¶

For the purpose of this quickstart, we will configure a ScyllaDB instance using Docker. You can skip this section if you have already installed ScyllaDB. To learn more about installing and configuring ScyllaDB in production environments, please refer to the Getting Started guide.

  1. Using Docker, follow the instructions to launch ScyllaDB.

  2. Start the Docker container, replacing the --name and --host name parameters with your own information. For example:

    docker run --name scylla-cdc-quickstart --hostname scylla-cdc-quickstart -d scylladb/scylla
    docker run --name scylla-cdc-quickstart-2 --hostname scylla-cdc-quickstart-2 -d scylladb/scylla --seeds="$(docker inspect --format='{{ .NetworkSettings.IPAddress }}' scylla-cdc-quickstart)"
    docker run --name scylla-cdc-quickstart-3 --hostname scylla-cdc-quickstart-3 -d scylladb/scylla --seeds="$(docker inspect --format='{{ .NetworkSettings.IPAddress }}' scylla-cdc-quickstart)"
    
  3. Run docker ps to show the exposed ports. The output should be similar to this example:

    docker ps
    CONTAINER ID   IMAGE                 COMMAND                  CREATED              STATUS              PORTS                                                            NAMES
    b72f341f53c0   scylladb/scylla       "/docker-entrypoint.…"   12 seconds ago       Up 11 seconds       22/tcp, 7000-7001/tcp, 9042/tcp, 9160/tcp, 9180/tcp, 10000/tcp   scylla-cdc-quickstart-3
    e1ac1ccb4d12   scylladb/scylla       "/docker-entrypoint.…"   16 seconds ago       Up 15 seconds       22/tcp, 7000-7001/tcp, 9042/tcp, 9160/tcp, 9180/tcp, 10000/tcp   scylla-cdc-quickstart-2
    f1668fba1e7b   scylladb/scylla       "/docker-entrypoint.…"   About a minute ago   Up About a minute   22/tcp, 7000-7001/tcp, 9042/tcp, 9160/tcp, 9180/tcp, 10000/tcp   scylla-cdc-quickstart
    

Creating a CDC-enabled table¶

Let’s connect to your ScyllaDB cluster and create a new CDC-enabled table. We will create an example table by issuing the following CQL query and insert some example data:

CREATE KEYSPACE quickstart_keyspace WITH REPLICATION = {'class': 'NetworkTopologyStrategy', 'replication_factor': 3};

CREATE TABLE quickstart_keyspace.orders(
   customer_id int,
   order_id int,
   product text,
   PRIMARY KEY(customer_id, order_id)) WITH cdc = {'enabled': true};

INSERT INTO quickstart_keyspace.orders(customer_id, order_id, product) VALUES (1, 1, 'pizza');
INSERT INTO quickstart_keyspace.orders(customer_id, order_id, product) VALUES (1, 2, 'cookies');
INSERT INTO quickstart_keyspace.orders(customer_id, order_id, product) VALUES (1, 3, 'tea');

If you already have a table you wish to use, but it does not have CDC enabled, you can turn it on by using the following CQL query:

ALTER TABLE keyspace.table_name with cdc = {'enabled': true};

To learn more about ScyllaDB CDC, visit Change Data Capture (CDC) page.

Kafka setup¶

ScyllaDB CDC Source Connector works well with both open-source Kafka and Confluent Platform. In this quickstart we will show how to install the Confluent Platform and deploy the connector (applicable to both open-source Kafka and Confluent Platform).

Installing Confluent Platform¶

If you are new to Confluent, download Confluent Platform.

  1. In the Download Confluent Platform section fill in your email address

  2. Open the Select Deployment Type drop-down and select ZIP

  3. Accept the Terms & Conditions and click DOWNLOAD FREE

  4. You will receive an email with instructions. Download / move the file to the desired location

  5. Continue with the setup following this document

Installing ScyllaDB CDC Source Connector¶

  1. Download or build ScyllaDB CDC Source Connector using the project build instructions

  2. Deploy the connector:

    1. If you use Confluent Platform, move connector JAR files to the share/java folder

    2. If you use open-source Kafka, make sure that plugin.path of Kafka Connect configuration contains the folder with connector JAR files

Connector configuration¶

After you have successfully configured ScyllaDB and Kafka, the next step is to configure the connector and start it up.

Configuration using Confluent Control Center¶

If you use Confluent Platform, the easiest way to configure and start up the ScyllaDB CDC Source Connector is to use Confluent Control Center web interface.

  1. Open the Confluent Control Center. By default, it is started at port 9021:

    Confluent Control Center main page
  2. Click on the cluster you want to start the connector in and open the “Connect” tab:

    Confluent Control Center "Connect" tab
  3. Click on the Kafka Connect cluster:

    Confluent Control Center "connect-default" cluster
  4. Click “Add connector”:

    Confluent Control Center "Add connector"
  5. Click “ScyllaConnector (Source Connector)”:

    Confluent Control Center "ScyllaConnector (Source Connector)"
  6. Configure the connector. You need to fill in these required configuration parameters:

    1. Name: the name of this configuration

    2. Key converter class, value converter class: converters that determine the format of produced messages. You can read more about them at Kafka Connect Deep Dive – Converters and Serialization Explained

    3. Hosts: contact points of ScyllaDB

    4. Namespace: a unique name that identifies the ScyllaDB cluster and that is used as a prefix for all schemas, topics.

    5. Table names: the names of CDC-enabled tables you want to replicate

    For the quickstart example here are the values we will use:

    1. Name: QuickstartConnector

    2. Key converter class, value converter class: org.apache.kafka.connect.json.JsonConverter

    3. Hosts: 172.17.0.2:9042 (ScyllaDB started in Docker)

    4. Namespace: QuickstartConnectorNamespace

    5. Table names: quickstart_keyspace.orders

    Confluent Control Center connector configuration
  7. Click “Continue” and “Launch”

  8. After a short while, a new QuickstartConnectorNamespace.quickstart_keyspace.orders topic will be automatically created and inserted rows will be replicated. You can browse them by going to the “Topics” tab, selecting QuickstartConnectorNamespace.quickstart_keyspace.orders topic, going to “Message” tab and inputting 0 to “Jump to offset” field:

    Confluent Control Center connector messages

Configuration using open-source Kafka¶

  1. Start Kafka Connect standalone using this guide. You will have to create a connector.properties file with the following contents:

    name = QuickstartConnector
    connector.class = com.scylladb.cdc.debezium.connector.ScyllaConnector
    key.converter = org.apache.kafka.connect.json.JsonConverter
    value.converter = org.apache.kafka.connect.json.JsonConverter
    scylla.cluster.ip.addresses = 172.17.0.2:9042
    scylla.name = QuickstartConnectorNamespace
    scylla.table.names = quickstart_keyspace.orders
    
  2. After starting the connector, you can see the generated messages by using kafka-console-consumer tool:

    bin/kafka-console-consumer --bootstrap-server localhost:9092 --topic QuickstartConnectorNamespace.quickstart_keyspace.orders --from-beginning
    

Additional information¶

  • ScyllaDB CDC Source Connector GitHub project

Was this page helpful?

PREVIOUS
ScyllaDB CDC Source Connector
NEXT
Integrate ScyllaDB with IOTA Chronicle
  • Create an issue
  • Edit this page

On this page

  • ScyllaDB CDC Source Connector Quickstart
    • Synopsis
    • ScyllaDB setup
      • ScyllaDB installation
      • Creating a CDC-enabled table
    • Kafka setup
      • Installing Confluent Platform
      • Installing ScyllaDB CDC Source Connector
    • Connector configuration
      • Configuration using Confluent Control Center
      • Configuration using open-source Kafka
    • Additional information
ScyllaDB Open Source
  • 6.2
    • master
    • 6.2
    • 6.1
    • 6.0
    • 5.4
    • 5.2
    • 5.1
  • Getting Started
    • Install ScyllaDB
      • Launch ScyllaDB on AWS
      • Launch ScyllaDB on GCP
      • Launch ScyllaDB on Azure
      • ScyllaDB Web Installer for Linux
      • Install ScyllaDB Linux Packages
      • Install scylla-jmx Package
      • Run ScyllaDB in Docker
      • Install ScyllaDB Without root Privileges
      • Air-gapped Server Installation
      • ScyllaDB Housekeeping and how to disable it
      • ScyllaDB Developer Mode
    • Configure ScyllaDB
    • ScyllaDB Configuration Reference
    • ScyllaDB Requirements
      • System Requirements
      • OS Support by Linux Distributions and Version
      • Cloud Instance Recommendations
      • ScyllaDB in a Shared Environment
    • Migrate to ScyllaDB
      • Migration Process from Cassandra to ScyllaDB
      • ScyllaDB and Apache Cassandra Compatibility
      • Migration Tools Overview
    • Integration Solutions
      • Integrate ScyllaDB with Spark
      • Integrate ScyllaDB with KairosDB
      • Integrate ScyllaDB with Presto
      • Integrate ScyllaDB with Elasticsearch
      • Integrate ScyllaDB with Kubernetes
      • Integrate ScyllaDB with the JanusGraph Graph Data System
      • Integrate ScyllaDB with DataDog
      • Integrate ScyllaDB with Kafka
      • Integrate ScyllaDB with IOTA Chronicle
      • Integrate ScyllaDB with Spring
      • Shard-Aware Kafka Connector for ScyllaDB
      • Install ScyllaDB with Ansible
      • Integrate ScyllaDB with Databricks
      • Integrate ScyllaDB with Jaeger Server
      • Integrate ScyllaDB with MindsDB
    • Tutorials
  • ScyllaDB for Administrators
    • Administration Guide
    • Procedures
      • Cluster Management
      • Backup & Restore
      • Change Configuration
      • Maintenance
      • Best Practices
      • Benchmarking ScyllaDB
      • Migrate from Cassandra to ScyllaDB
      • Disable Housekeeping
    • Security
      • ScyllaDB Security Checklist
      • Enable Authentication
      • Enable and Disable Authentication Without Downtime
      • Creating a Custom Superuser
      • Generate a cqlshrc File
      • Reset Authenticator Password
      • Enable Authorization
      • Grant Authorization CQL Reference
      • Certificate-based Authentication
      • Role Based Access Control (RBAC)
      • Encryption: Data in Transit Client to Node
      • Encryption: Data in Transit Node to Node
      • Generating a self-signed Certificate Chain Using openssl
      • Configure SaslauthdAuthenticator
    • Admin Tools
      • Nodetool Reference
      • CQLSh
      • Admin REST API
      • Tracing
      • ScyllaDB SStable
      • ScyllaDB Types
      • SSTableLoader
      • cassandra-stress
      • SSTabledump
      • SSTableMetadata
      • ScyllaDB Logs
      • Seastar Perftune
      • Virtual Tables
      • Reading mutation fragments
      • Maintenance socket
      • Maintenance mode
      • Task manager
    • ScyllaDB Monitoring Stack
    • ScyllaDB Operator
    • ScyllaDB Manager
    • Upgrade Procedures
      • ScyllaDB Versioning
      • ScyllaDB Open Source Upgrade
      • ScyllaDB Open Source to ScyllaDB Enterprise Upgrade
      • ScyllaDB Image
      • ScyllaDB Enterprise
    • System Configuration
      • System Configuration Guide
      • scylla.yaml
      • ScyllaDB Snitches
    • Benchmarking ScyllaDB
    • ScyllaDB Diagnostic Tools
  • ScyllaDB for Developers
    • Develop with ScyllaDB
    • Tutorials and Example Projects
    • Learn to Use ScyllaDB
    • ScyllaDB Alternator
    • ScyllaDB Drivers
      • ScyllaDB CQL Drivers
      • ScyllaDB DynamoDB Drivers
  • CQL Reference
    • CQLSh: the CQL shell
    • Appendices
    • Compaction
    • Consistency Levels
    • Consistency Level Calculator
    • Data Definition
    • Data Manipulation
      • SELECT
      • INSERT
      • UPDATE
      • DELETE
      • BATCH
    • Data Types
    • Definitions
    • Global Secondary Indexes
    • Expiring Data with Time to Live (TTL)
    • Functions
    • Wasm support for user-defined functions
    • JSON Support
    • Materialized Views
    • Non-Reserved CQL Keywords
    • Reserved CQL Keywords
    • Service Levels
    • ScyllaDB CQL Extensions
  • Alternator: DynamoDB API in Scylla
    • Getting Started With ScyllaDB Alternator
    • ScyllaDB Alternator for DynamoDB users
  • Features
    • Lightweight Transactions
    • Global Secondary Indexes
    • Local Secondary Indexes
    • Materialized Views
    • Counters
    • Change Data Capture
      • CDC Overview
      • The CDC Log Table
      • Basic operations in CDC
      • CDC Streams
      • CDC Stream Generations
      • Querying CDC Streams
      • Advanced column types
      • Preimages and postimages
      • Data Consistency in CDC
    • Workload Attributes
  • ScyllaDB Architecture
    • Data Distribution with Tablets
    • ScyllaDB Ring Architecture
    • ScyllaDB Fault Tolerance
    • Consistency Level Console Demo
    • ScyllaDB Anti-Entropy
      • ScyllaDB Hinted Handoff
      • ScyllaDB Read Repair
      • ScyllaDB Repair
    • SSTable
      • ScyllaDB SSTable - 2.x
      • ScyllaDB SSTable - 3.x
    • Compaction Strategies
    • Raft Consensus Algorithm in ScyllaDB
    • Zero-token Nodes
  • Troubleshooting ScyllaDB
    • Errors and Support
      • Report a ScyllaDB problem
      • Error Messages
      • Change Log Level
    • ScyllaDB Startup
      • Ownership Problems
      • ScyllaDB will not Start
      • ScyllaDB Python Script broken
    • Upgrade
      • Inaccessible configuration files after ScyllaDB upgrade
    • Cluster and Node
      • Handling Node Failures
      • Failure to Add, Remove, or Replace a Node
      • Failed Decommission Problem
      • Cluster Timeouts
      • Node Joined With No Data
      • NullPointerException
      • Failed Schema Sync
    • Data Modeling
      • ScyllaDB Large Partitions Table
      • ScyllaDB Large Rows and Cells Table
      • Large Partitions Hunting
      • Failure to Update the Schema
    • Data Storage and SSTables
      • Space Utilization Increasing
      • Disk Space is not Reclaimed
      • SSTable Corruption Problem
      • Pointless Compactions
      • Limiting Compaction
    • CQL
      • Time Range Query Fails
      • COPY FROM Fails
      • CQL Connection Table
    • ScyllaDB Monitor and Manager
      • Manager and Monitoring integration
      • Manager lists healthy nodes as down
    • Installation and Removal
      • Removing ScyllaDB on Ubuntu breaks system packages
  • Knowledge Base
    • Upgrading from experimental CDC
    • Compaction
    • Consistency in ScyllaDB
    • Counting all rows in a table is slow
    • CQL Query Does Not Display Entire Result Set
    • When CQLSh query returns partial results with followed by “More”
    • Run ScyllaDB and supporting services as a custom user:group
    • Customizing CPUSET
    • Decoding Stack Traces
    • Snapshots and Disk Utilization
    • DPDK mode
    • Debug your database with Flame Graphs
    • How to Change gc_grace_seconds for a Table
    • Gossip in ScyllaDB
    • Increase Permission Cache to Avoid Non-paged Queries
    • How does ScyllaDB LWT Differ from Apache Cassandra ?
    • Map CPUs to ScyllaDB Shards
    • ScyllaDB Memory Usage
    • NTP Configuration for ScyllaDB
    • Updating the Mode in perftune.yaml After a ScyllaDB Upgrade
    • POSIX networking for ScyllaDB
    • ScyllaDB consistency quiz for administrators
    • Recreate RAID devices
    • How to Safely Increase the Replication Factor
    • ScyllaDB and Spark integration
    • Increase ScyllaDB resource limits over systemd
    • ScyllaDB Seed Nodes
    • How to Set up a Swap Space
    • ScyllaDB Snapshots
    • ScyllaDB payload sent duplicated static columns
    • Stopping a local repair
    • System Limits
    • How to flush old tombstones from a table
    • Time to Live (TTL) and Compaction
    • ScyllaDB Nodes are Unresponsive
    • Update a Primary Key
    • Using the perf utility with ScyllaDB
    • Configure ScyllaDB Networking with Multiple NIC/IP Combinations
  • Reference
    • AWS Images
    • Azure Images
    • GCP Images
    • Configuration Parameters
    • Glossary
    • Limits
    • API Reference (BETA)
    • Metrics (BETA)
  • ScyllaDB FAQ
  • Contribute to ScyllaDB
Docs Tutorials University Contact Us About Us
© 2025, ScyllaDB. All rights reserved. | Terms of Service | Privacy Policy | ScyllaDB, and ScyllaDB Cloud, are registered trademarks of ScyllaDB, Inc.
Last updated on 08 May 2025.
Powered by Sphinx 7.4.7 & ScyllaDB Theme 1.8.6