From 50eb80efd452b5cfe0c375465bc5d09bdeb27ea8 Mon Sep 17 00:00:00 2001 From: nikhil-ctds Date: Thu, 23 May 2024 10:44:51 +0530 Subject: [PATCH] Fix Checkstyle --- .../io/debezium/oracle/DebeziumSource.java | 3 +-- .../oracle/PulsarDatabaseHistory.java | 21 ++++++++++++------- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/DebeziumSource.java b/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/DebeziumSource.java index d1694d6bfd4a3..892c4dcb5a8b7 100644 --- a/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/DebeziumSource.java +++ b/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/DebeziumSource.java @@ -19,6 +19,7 @@ package org.apache.pulsar.io.debezium.oracle; import io.debezium.relational.HistorizedRelationalDatabaseConnectorConfig; +import java.util.Map; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.StringUtils; import org.apache.pulsar.common.naming.TopicName; @@ -26,8 +27,6 @@ import org.apache.pulsar.io.kafka.connect.KafkaConnectSource; import org.apache.pulsar.io.kafka.connect.PulsarKafkaWorkerConfig; -import java.util.Map; - @Slf4j public abstract class DebeziumSource extends KafkaConnectSource { private static final String DEFAULT_CONVERTER = "org.apache.kafka.connect.json.JsonConverter"; diff --git a/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/PulsarDatabaseHistory.java b/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/PulsarDatabaseHistory.java index ef8430ffc9893..ab84579e2cd92 100644 --- a/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/PulsarDatabaseHistory.java +++ b/pulsar-io/debezium/oracle/src/main/java/org/apache/pulsar/io/debezium/oracle/PulsarDatabaseHistory.java @@ -18,6 +18,7 @@ */ package org.apache.pulsar.io.debezium.oracle; +import static org.apache.commons.lang3.StringUtils.isBlank; import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.annotations.VisibleForTesting; @@ -31,20 +32,24 @@ import io.debezium.relational.history.SchemaHistory; import io.debezium.relational.history.SchemaHistoryException; import io.debezium.relational.history.SchemaHistoryListener; -import lombok.extern.slf4j.Slf4j; -import org.apache.kafka.common.config.ConfigDef.Importance; -import org.apache.kafka.common.config.ConfigDef.Type; -import org.apache.kafka.common.config.ConfigDef.Width; -import org.apache.pulsar.client.api.*; - import java.io.IOException; import java.util.Collections; import java.util.HashMap; import java.util.Map; import java.util.UUID; import java.util.function.Consumer; - -import static org.apache.commons.lang3.StringUtils.isBlank; +import lombok.extern.slf4j.Slf4j; +import org.apache.kafka.common.config.ConfigDef.Importance; +import org.apache.kafka.common.config.ConfigDef.Type; +import org.apache.kafka.common.config.ConfigDef.Width; +import org.apache.pulsar.client.api.ClientBuilder; +import org.apache.pulsar.client.api.Message; +import org.apache.pulsar.client.api.MessageId; +import org.apache.pulsar.client.api.Producer; +import org.apache.pulsar.client.api.PulsarClient; +import org.apache.pulsar.client.api.PulsarClientException; +import org.apache.pulsar.client.api.Reader; +import org.apache.pulsar.client.api.Schema; /** * A {@link SchemaHistory} implementation that records schema changes as normal pulsar messages on the specified