From ef593f85ad7139d80ec88e63166489ba62c9adc1 Mon Sep 17 00:00:00 2001 From: David Sloan Date: Wed, 25 Oct 2023 16:08:56 +0100 Subject: [PATCH] Fix odd class name, remove netty hack --- .../streamreactor/connect/aws/s3/sink/S3SinkConnector.scala | 4 ++-- .../connect/aws/s3/sink/config/SinkConfigDef$.scala | 6 +++--- .../connect/aws/s3/config/S3ConfigSettingsTest.scala | 4 ++-- project/Settings.scala | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/S3SinkConnector.scala b/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/S3SinkConnector.scala index 3cc6fb6b2..f8fa65c04 100644 --- a/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/S3SinkConnector.scala +++ b/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/S3SinkConnector.scala @@ -18,7 +18,7 @@ package io.lenses.streamreactor.connect.aws.s3.sink import com.datamountaineer.streamreactor.common.utils.JarManifest import com.typesafe.scalalogging.LazyLogging import io.lenses.streamreactor.connect.aws.s3.config.S3ConfigSettings -import io.lenses.streamreactor.connect.aws.s3.sink.config.SinkConfigDef$ +import io.lenses.streamreactor.connect.aws.s3.sink.config.SinkConfigDef import io.lenses.streamreactor.connect.cloud.common.config.TaskDistributor import org.apache.kafka.common.config.ConfigDef import org.apache.kafka.connect.connector.Task @@ -35,7 +35,7 @@ class S3SinkConnector extends SinkConnector with LazyLogging { override def taskClass(): Class[_ <: Task] = classOf[S3SinkTask] - override def config(): ConfigDef = SinkConfigDef$.config + override def config(): ConfigDef = SinkConfigDef.config override def start(props: util.Map[String, String]): Unit = { logger.info(s"Creating S3 sink connector") diff --git a/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/config/SinkConfigDef$.scala b/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/config/SinkConfigDef$.scala index 96025a15f..7d5d3649d 100644 --- a/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/config/SinkConfigDef$.scala +++ b/kafka-connect-aws-s3/src/main/scala/io/lenses/streamreactor/connect/aws/s3/sink/config/SinkConfigDef$.scala @@ -38,7 +38,7 @@ import io.lenses.streamreactor.connect.cloud.common.sink.config.FlushSettings import io.lenses.streamreactor.connect.cloud.common.sink.config.padding.PaddingStrategyConfigKeys import io.lenses.streamreactor.connect.cloud.common.sink.config.padding.PaddingStrategySettings -object SinkConfigDef$ +object SinkConfigDef extends CommonConfigDef with FlushConfigKeys with LocalStagingAreaConfigKeys @@ -72,7 +72,7 @@ object SinkConfigDef$ } -class SinkConfigDef$() extends ConfigDef with LazyLogging { +class SinkConfigDef() extends ConfigDef with LazyLogging { private val processorChain: List[ConfigDefProcessor] = List(new LowerCaseKeyConfigDefProcessor(CONNECTOR_PREFIX), new DeprecationConfigDefProcessor) @@ -108,7 +108,7 @@ class SinkConfigDef$() extends ConfigDef with LazyLogging { } case class SinkConfigDefBuilder(props: util.Map[String, String]) - extends BaseConfig(S3ConfigSettings.CONNECTOR_PREFIX, SinkConfigDef$.config, props) + extends BaseConfig(S3ConfigSettings.CONNECTOR_PREFIX, SinkConfigDef.config, props) with KcqlSettings with ErrorPolicySettings with NumberRetriesSettings diff --git a/kafka-connect-aws-s3/src/test/scala/io/lenses/streamreactor/connect/aws/s3/config/S3ConfigSettingsTest.scala b/kafka-connect-aws-s3/src/test/scala/io/lenses/streamreactor/connect/aws/s3/config/S3ConfigSettingsTest.scala index 64d0f4e66..2f670329a 100644 --- a/kafka-connect-aws-s3/src/test/scala/io/lenses/streamreactor/connect/aws/s3/config/S3ConfigSettingsTest.scala +++ b/kafka-connect-aws-s3/src/test/scala/io/lenses/streamreactor/connect/aws/s3/config/S3ConfigSettingsTest.scala @@ -16,7 +16,7 @@ package io.lenses.streamreactor.connect.aws.s3.config import com.typesafe.scalalogging.LazyLogging -import io.lenses.streamreactor.connect.aws.s3.sink.config.SinkConfigDef$ +import io.lenses.streamreactor.connect.aws.s3.sink.config.SinkConfigDef import io.lenses.streamreactor.connect.aws.s3.source.config.S3SourceConfigDef import org.scalatest.flatspec.AnyFlatSpec import org.scalatest.matchers.should.Matchers @@ -33,7 +33,7 @@ class S3ConfigSettingsTest extends AnyFlatSpec with Matchers with LazyLogging { "S3ConfigSettings" should "ensure all keys are lower case" in { val configKeys = - SinkConfigDef$.config.configKeys().keySet().asScala ++ S3SourceConfigDef.config.configKeys().keySet().asScala + SinkConfigDef.config.configKeys().keySet().asScala ++ S3SourceConfigDef.config.configKeys().keySet().asScala configKeys.size shouldBe 47 configKeys.foreach { diff --git a/project/Settings.scala b/project/Settings.scala index 44b89b6b0..28b55c8a4 100644 --- a/project/Settings.scala +++ b/project/Settings.scala @@ -205,7 +205,7 @@ object Settings extends Dependencies { hadoopCommon, hadoopMapReduceClientCore, woodstoxCore, - ) /*++ nettyOverrides*/ ++ avroOverrides, + ) ++ nettyOverrides ++ avroOverrides, ), ) }