From c5d7a2168efe65e5e7620880c4c9eb5fbf9dc922 Mon Sep 17 00:00:00 2001 From: Akihiro Okuno Date: Tue, 10 Oct 2023 14:58:15 +0900 Subject: [PATCH] fix(schema-importer): fix warning due to Netty's native transport library When we run a container of schema-importer image of M1 Mac, we got a warnings as follows: [main] WARN com.datastax.driver.core.NettyUtil - Found Netty's native epoll transport in the classpath, but epoll is not available. Using NIO instead. java.lang.UnsatisfiedLinkError: could not load a native library: netty_transport_native_epoll_aarch_64 at io.netty.util.internal.NativeLibraryLoader.load(NativeLibraryLoader.java:239) This is due to the missing of Netty's epoll library for Arm architecture. To solve this, this commits add an dependencies on amd64 and arm64 explicitly. --- schema-importer/app/build.gradle.kts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/schema-importer/app/build.gradle.kts b/schema-importer/app/build.gradle.kts index 49e30f1..c6a10c0 100644 --- a/schema-importer/app/build.gradle.kts +++ b/schema-importer/app/build.gradle.kts @@ -26,6 +26,14 @@ dependencies { implementation("org.slf4j:slf4j-api:2.0.7") implementation("org.slf4j:slf4j-simple:2.0.7") + // These dependencies are added as tentative solution for the warnings caused by missing of + // Netty's native transport library. + // Once this issue is addressed in the ScalarDB core, these will be removed. + implementation("io.netty:netty-transport-native-epoll:4.1.99.Final:linux-x86_64") + implementation("io.netty:netty-transport-native-epoll:4.1.99.Final:linux-aarch_64") + implementation("io.netty:netty-transport-native-kqueue:4.1.99.Final:osx-x86_64") + implementation("io.netty:netty-transport-native-kqueue:4.1.99.Final:osx-aarch_64") + testImplementation("org.jetbrains.kotlin:kotlin-test-junit5") testImplementation("org.junit.jupiter:junit-jupiter-engine:5.9.2") testImplementation("io.mockk:mockk:1.13.5")