From 9d27719ee1488727426f89960734f3cb085a3190 Mon Sep 17 00:00:00 2001 From: mfvitale Date: Thu, 28 Mar 2024 14:16:22 +0100 Subject: [PATCH] DBZ-7717 LogPositionValidator is no more needed in Db2Connection --- src/main/java/io/debezium/connector/db2/Db2Connection.java | 1 - src/main/java/io/debezium/connector/db2/Db2ConnectorTask.java | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/java/io/debezium/connector/db2/Db2Connection.java b/src/main/java/io/debezium/connector/db2/Db2Connection.java index affeb91..f2d473b 100644 --- a/src/main/java/io/debezium/connector/db2/Db2Connection.java +++ b/src/main/java/io/debezium/connector/db2/Db2Connection.java @@ -116,7 +116,6 @@ public class Db2Connection extends JdbcConnection { */ public Db2Connection(JdbcConfiguration config) { super(config, FACTORY, QUOTED_CHARACTER, QUOTED_CHARACTER); - this.logPositionValidator = this::validateLogPosition; lsnToInstantCache = new BoundedConcurrentHashMap<>(100); realDatabaseName = retrieveRealDatabaseName(); } diff --git a/src/main/java/io/debezium/connector/db2/Db2ConnectorTask.java b/src/main/java/io/debezium/connector/db2/Db2ConnectorTask.java index 0c2f165..7b20a23 100644 --- a/src/main/java/io/debezium/connector/db2/Db2ConnectorTask.java +++ b/src/main/java/io/debezium/connector/db2/Db2ConnectorTask.java @@ -100,7 +100,7 @@ public ChangeEventSourceCoordinator start(Config final SnapshotterService snapshotterService = connectorConfig.getServiceRegistry().tryGetService(SnapshotterService.class); - validateAndLoadSchemaHistory(connectorConfig, metadataConnection, previousOffsets, schema, + validateAndLoadSchemaHistory(connectorConfig, metadataConnection::validateLogPosition, previousOffsets, schema, snapshotterService.getSnapshotter()); taskContext = new Db2TaskContext(connectorConfig, schema);