使用Debezium跟踪特定的表



我使用Debezium嵌入式oracle连接器来跟踪我的表中的变化。是否有一种属性/方法可以从模式中跟踪特定的表。我的模式有很多表,我不想跟踪所有表的变化。

我现在已经添加了这些配置:

public io.debezium.config.Configuration debeziumConnectorConfig() throws IOException {
File offsetStorageTempFile = File.createTempFile("offsets_", ".dat");
File dbHistoryTempFile = File.createTempFile("dbhistory_", ".dat");
return io.debezium.config.Configuration.create()
.with("name", "oracle-connector")
.with("connector.class", "io.debezium.connector.oracle.OracleConnector")
.with("offset.storage", "org.apache.kafka.connect.storage.FileOffsetBackingStore")
.with("offset.storage.file.filename", offsetStorageTempFile.getAbsolutePath())
.with("offset.flush.interval.ms", "60000")
.with("database.hostname", customerDbHost)
.with("database.port", customerDbPort)
.with("database.user", customerDbUsername)
.with("database.password", customerDbPassword)
.with("database.dbname", customerDbName)
.with("database.include.list", customerDbName)
.with("schema.include.list", "schema")
.with("table.include.list", "tablename")
.with("topic.prefix", "prefix")
.with("database.server.name", "dbservername")
.with("snapshot.mode", "schema_only")
.with("include.schema.changes", "false")
.with("schema.history.internal.kafka.topic", "dbschema")
.with("schema.history.internal.kafka.bootstrap.servers", "localhost:9092")
.with("bootstrap.servers", "localhost:9092")
.build();
}

当然,可以使用这些表来配置特定的表。包括财产

最新更新