diff --git a/buildSrc/src/main/kotlin/Versions.kt b/buildSrc/src/main/kotlin/Versions.kt index df6cbed..f72c017 100644 --- a/buildSrc/src/main/kotlin/Versions.kt +++ b/buildSrc/src/main/kotlin/Versions.kt @@ -8,7 +8,7 @@ object Versions { const val ktor = "2.3.10" const val radarJersey = "0.11.1" - const val radarCommons = "1.1.3-SNAPSHOT" + const val radarCommons = "1.1.2" const val radarSchemas = "0.8.8" const val jackson = "2.15.3" const val slf4j = "2.0.13" @@ -22,6 +22,4 @@ object Versions { const val mockitoKotlin = "5.3.1" const val grizzly = "4.0.2" const val hamcrest = "2.2" - - const val wrapper = "8.4" } diff --git a/radar-gateway/src/integrationTest/kotlin/org/radarbase/gateway/resource/KafkaTopicsTest.kt b/radar-gateway/src/integrationTest/kotlin/org/radarbase/gateway/resource/KafkaTopicsTest.kt index e4ffc01..42f5858 100644 --- a/radar-gateway/src/integrationTest/kotlin/org/radarbase/gateway/resource/KafkaTopicsTest.kt +++ b/radar-gateway/src/integrationTest/kotlin/org/radarbase/gateway/resource/KafkaTopicsTest.kt @@ -78,7 +78,7 @@ class KafkaTopicsTest { } val retriever = schemaRetriever(SCHEMA_REGISTRY_URL) { - httpClient { + httpClient = HttpClient(CIO) { timeout(10.seconds) } } diff --git a/radar-gateway/src/main/kotlin/org/radarbase/gateway/inject/SchemaRetrieverFactory.kt b/radar-gateway/src/main/kotlin/org/radarbase/gateway/inject/SchemaRetrieverFactory.kt index f73880b..cb4336c 100644 --- a/radar-gateway/src/main/kotlin/org/radarbase/gateway/inject/SchemaRetrieverFactory.kt +++ b/radar-gateway/src/main/kotlin/org/radarbase/gateway/inject/SchemaRetrieverFactory.kt @@ -14,7 +14,6 @@ import org.radarbase.gateway.config.GatewayConfig import org.radarbase.producer.io.timeout import org.radarbase.producer.schema.SchemaRetriever import org.radarbase.producer.schema.SchemaRetriever.Companion.schemaRetriever -import org.slf4j.LoggerFactory import java.util.function.Supplier import kotlin.time.Duration.Companion.seconds @@ -35,10 +34,10 @@ class SchemaRetrieverFactory( ?: config.kafka.serialization[USER_INFO_CONFIG].asNonEmptyString() return schemaRetriever(baseUrl = server.urlString) { - if (basicCredentials != null && basicCredentials.contains(':')) { - val (apiKey, apiSecret) = basicCredentials.split(':', limit = 2) - httpClient = HttpClient(CIO) { - timeout(30.seconds) + httpClient = HttpClient(CIO) { + timeout(30.seconds) + if (basicCredentials != null && basicCredentials.contains(':')) { + val (apiKey, apiSecret) = basicCredentials.split(':', limit = 2) install(Auth) { basic { sendWithoutRequest { true } @@ -54,6 +53,5 @@ class SchemaRetrieverFactory( companion object { private fun Any?.asNonEmptyString(): String? = (this as? String)?.takeIf { it.isNotEmpty() } - private val logger = LoggerFactory.getLogger(SchemaRetrieverFactory::class.java) } }