Ingest data from Citus CDC
RisingWave supports ingesting change data capture (CDC) data from Citus database. Version 10.2 of Citus is supported.
Citus database is an extension to PostgreSQL that transforms PostgreSQL into a distributed database. For more details, see Citus data.
Ingesting CDC data from Citus database is currently in Beta. Please contact us if you encounter any issues or have feedback.
Set up Citus
-
Create a
superuser
role in the Citus cluster.---create role on coordinator node
CREATE ROLE dbz Superuser LOGIN;
---create role on worker nodes
SELECT run_command_on_workers ($cmd$
CREATE ROLE dbz Superuser LOGIN;
$cmd$); -
Ensure that
wal_level
islogical
on each worker node by modifyingpostgresql.conf
. -
Set the replica identity to
FULL
for the table you want to ingest data from.---execute on coordinator node
ALTER TABLE github_events REPLICA IDENTITY FULL;
Limitations
There are a few limitations when ingesting CDC data from Citus in RisingWave.
- A PostgreSQL
superuser
role is required. - Only distributed tables are supported.
- Newly added worker nodes are not detected.
Notes about running RisingWave from binaries
If you are running RisingWave locally from binaries and intend to use the native CDC source connectors or the JDBC sink connector, make sure that you have JDK 11 or later versions installed in your environment.