diff --git a/java/connector-node/risingwave-connector-service/src/main/java/com/risingwave/connector/source/common/DbzConnectorConfig.java b/java/connector-node/risingwave-connector-service/src/main/java/com/risingwave/connector/source/common/DbzConnectorConfig.java index 8ba569c7aea7..ea4f5d2003df 100644 --- a/java/connector-node/risingwave-connector-service/src/main/java/com/risingwave/connector/source/common/DbzConnectorConfig.java +++ b/java/connector-node/risingwave-connector-service/src/main/java/com/risingwave/connector/source/common/DbzConnectorConfig.java @@ -204,6 +204,23 @@ public DbzConnectorConfig( } } + // adapt value of sslmode to the expected value + var sslMode = postgresProps.getProperty("database.sslmode"); + if (sslMode != null) { + switch (sslMode) { + case "disabled": + sslMode = "disable"; + break; + case "preferred": + sslMode = "prefer"; + break; + case "required": + sslMode = "require"; + break; + } + postgresProps.setProperty("database.sslmode", sslMode); + } + dbzProps.putAll(postgresProps); if (isCdcSourceJob) {