From e85ff96a8a9c371d08450e92ab033bf841997957 Mon Sep 17 00:00:00 2001 From: Kannan J Date: Tue, 6 Aug 2024 10:08:49 +0000 Subject: [PATCH 1/6] Upgrade Netty to 4.1.110 and tcnative to 2.0.65 --- SECURITY.md | 9 +++--- .../io/grpc/netty/shaded/ShadingTest.java | 2 +- repositories.bzl | 28 +++++++++---------- 3 files changed, 20 insertions(+), 19 deletions(-) diff --git a/SECURITY.md b/SECURITY.md index 774579bf68b..3df480fb96a 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -395,10 +395,11 @@ grpc-netty version | netty-handler version | netty-tcnative-boringssl-static ver 1.48.x-1.49.x | 4.1.77.Final | 2.0.53.Final 1.50.x-1.53.x | 4.1.79.Final | 2.0.54.Final 1.54.x-1.55.x | 4.1.87.Final | 2.0.56.Final -1.56.x | 4.1.87.Final | 2.0.61.Final -1.57.x-1.58.x | 4.1.93.Final | 2.0.61.Final -1.59.x | 4.1.97.Final | 2.0.61.Final -1.60.x- | 4.1.100.Final | 2.0.61.Final +1.56.x | 4.1.87.Final | 2.0.65.Final +1.57.x-1.58.x | 4.1.93.Final | 2.0.65.Final +1.59.x | 4.1.97.Final | 2.0.65.Final +1.60.x-1.65.x | 4.1.110.Final | 2.0.65.Final +1.66.x | 4.1.110.Final | 2.0.65.Final _(grpc-netty-shaded avoids issues with keeping these versions in sync.)_ diff --git a/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java b/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java index 7a5e4b43c8b..89803998925 100644 --- a/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java +++ b/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java @@ -79,7 +79,7 @@ public void nettyResourcesUpdated() throws IOException { InputStream inputStream = NettyChannelBuilder.class.getClassLoader() .getResourceAsStream( "META-INF/native-image/io.grpc.netty.shaded.io.netty/netty-transport/" - + "reflection-config.json"); + + "reflect-config.json"); assertThat(inputStream).isNotNull(); Scanner s = new Scanner(inputStream, StandardCharsets.UTF_8.name()).useDelimiter("\\A"); diff --git a/repositories.bzl b/repositories.bzl index af3acc8ddcf..455e9dcf3ca 100644 --- a/repositories.bzl +++ b/repositories.bzl @@ -26,20 +26,20 @@ IO_GRPC_GRPC_JAVA_ARTIFACTS = [ "com.google.truth:truth:1.4.2", "com.squareup.okhttp:okhttp:2.7.5", "com.squareup.okio:okio:2.10.0", # 3.0+ needs swapping to -jvm; need work to avoid flag-day - "io.netty:netty-buffer:4.1.100.Final", - "io.netty:netty-codec-http2:4.1.100.Final", - "io.netty:netty-codec-http:4.1.100.Final", - "io.netty:netty-codec-socks:4.1.100.Final", - "io.netty:netty-codec:4.1.100.Final", - "io.netty:netty-common:4.1.100.Final", - "io.netty:netty-handler-proxy:4.1.100.Final", - "io.netty:netty-handler:4.1.100.Final", - "io.netty:netty-resolver:4.1.100.Final", - "io.netty:netty-tcnative-boringssl-static:2.0.61.Final", - "io.netty:netty-tcnative-classes:2.0.61.Final", - "io.netty:netty-transport-native-epoll:jar:linux-x86_64:4.1.100.Final", - "io.netty:netty-transport-native-unix-common:4.1.100.Final", - "io.netty:netty-transport:4.1.100.Final", + "io.netty:netty-buffer:4.1.110.Final", + "io.netty:netty-codec-http2:4.1.110.Final", + "io.netty:netty-codec-http:4.1.110.Final", + "io.netty:netty-codec-socks:4.1.110.Final", + "io.netty:netty-codec:4.1.110.Final", + "io.netty:netty-common:4.1.110.Final", + "io.netty:netty-handler-proxy:4.1.110.Final", + "io.netty:netty-handler:4.1.110.Final", + "io.netty:netty-resolver:4.1.110.Final", + "io.netty:netty-tcnative-boringssl-static:2.0.65.Final", + "io.netty:netty-tcnative-classes:2.0.65.Final", + "io.netty:netty-transport-native-epoll:jar:linux-x86_64:4.1.110.Final", + "io.netty:netty-transport-native-unix-common:4.1.110.Final", + "io.netty:netty-transport:4.1.110.Final", "io.opencensus:opencensus-api:0.31.0", "io.opencensus:opencensus-contrib-grpc-metrics:0.31.0", "io.perfmark:perfmark-api:0.27.0", From bd6b0137164e958c97c3b9d654434c148032e994 Mon Sep 17 00:00:00 2001 From: Kannan J Date: Tue, 6 Aug 2024 10:15:50 +0000 Subject: [PATCH 2/6] Change versions in MODULE.bazel as well. --- MODULE.bazel | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/MODULE.bazel b/MODULE.bazel index 2b5d85490f3..81c3249f47a 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -22,20 +22,20 @@ IO_GRPC_GRPC_JAVA_ARTIFACTS = [ "com.google.truth:truth:1.4.2", "com.squareup.okhttp:okhttp:2.7.5", "com.squareup.okio:okio:2.10.0", # 3.0+ needs swapping to -jvm; need work to avoid flag-day - "io.netty:netty-buffer:4.1.100.Final", - "io.netty:netty-codec-http2:4.1.100.Final", - "io.netty:netty-codec-http:4.1.100.Final", - "io.netty:netty-codec-socks:4.1.100.Final", - "io.netty:netty-codec:4.1.100.Final", - "io.netty:netty-common:4.1.100.Final", - "io.netty:netty-handler-proxy:4.1.100.Final", - "io.netty:netty-handler:4.1.100.Final", - "io.netty:netty-resolver:4.1.100.Final", - "io.netty:netty-tcnative-boringssl-static:2.0.61.Final", - "io.netty:netty-tcnative-classes:2.0.61.Final", - "io.netty:netty-transport-native-epoll:jar:linux-x86_64:4.1.100.Final", - "io.netty:netty-transport-native-unix-common:4.1.100.Final", - "io.netty:netty-transport:4.1.100.Final", + "io.netty:netty-buffer:4.1.110.Final", + "io.netty:netty-codec-http2:4.1.110.Final", + "io.netty:netty-codec-http:4.1.110.Final", + "io.netty:netty-codec-socks:4.1.110.Final", + "io.netty:netty-codec:4.1.110.Final", + "io.netty:netty-common:4.1.110.Final", + "io.netty:netty-handler-proxy:4.1.110.Final", + "io.netty:netty-handler:4.1.110.Final", + "io.netty:netty-resolver:4.1.110.Final", + "io.netty:netty-tcnative-boringssl-static:2.0.65.Final", + "io.netty:netty-tcnative-classes:2.0.65.Final", + "io.netty:netty-transport-native-epoll:jar:linux-x86_64:4.1.110.Final", + "io.netty:netty-transport-native-unix-common:4.1.110.Final", + "io.netty:netty-transport:4.1.110.Final", "io.opencensus:opencensus-api:0.31.0", "io.opencensus:opencensus-contrib-grpc-metrics:0.31.0", "io.perfmark:perfmark-api:0.27.0", From 06caf4cc3e0640fd3faabae7afd9d0778a07b06c Mon Sep 17 00:00:00 2001 From: Kannan J Date: Tue, 6 Aug 2024 10:41:56 +0000 Subject: [PATCH 3/6] Use reflection-config.json instead of reflect-config.json --- .../src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java b/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java index 89803998925..7a5e4b43c8b 100644 --- a/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java +++ b/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java @@ -79,7 +79,7 @@ public void nettyResourcesUpdated() throws IOException { InputStream inputStream = NettyChannelBuilder.class.getClassLoader() .getResourceAsStream( "META-INF/native-image/io.grpc.netty.shaded.io.netty/netty-transport/" - + "reflect-config.json"); + + "reflection-config.json"); assertThat(inputStream).isNotNull(); Scanner s = new Scanner(inputStream, StandardCharsets.UTF_8.name()).useDelimiter("\\A"); From f4733a2d2ecf80908ee48aec50003d9a82b0f7e5 Mon Sep 17 00:00:00 2001 From: Kannan J Date: Tue, 6 Aug 2024 10:57:14 +0000 Subject: [PATCH 4/6] Fix version --- SECURITY.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/SECURITY.md b/SECURITY.md index 3df480fb96a..211f4cad097 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -395,10 +395,10 @@ grpc-netty version | netty-handler version | netty-tcnative-boringssl-static ver 1.48.x-1.49.x | 4.1.77.Final | 2.0.53.Final 1.50.x-1.53.x | 4.1.79.Final | 2.0.54.Final 1.54.x-1.55.x | 4.1.87.Final | 2.0.56.Final -1.56.x | 4.1.87.Final | 2.0.65.Final -1.57.x-1.58.x | 4.1.93.Final | 2.0.65.Final -1.59.x | 4.1.97.Final | 2.0.65.Final -1.60.x-1.65.x | 4.1.110.Final | 2.0.65.Final +1.56.x | 4.1.87.Final | 2.0.61.Final +1.57.x-1.58.x | 4.1.93.Final | 2.0.61.Final +1.59.x | 4.1.97.Final | 2.0.61.Final +1.60.x-1.65.x | 4.1.100.Final | 2.0.61.Final 1.66.x | 4.1.110.Final | 2.0.65.Final _(grpc-netty-shaded avoids issues with keeping these versions in sync.)_ From 43d68613a8bf3d94c1373593061a8c18b54e55db Mon Sep 17 00:00:00 2001 From: Kannan J Date: Tue, 6 Aug 2024 14:08:26 +0000 Subject: [PATCH 5/6] Change gRPC version applied --- SECURITY.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SECURITY.md b/SECURITY.md index 211f4cad097..5c5e3598b29 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -398,8 +398,8 @@ grpc-netty version | netty-handler version | netty-tcnative-boringssl-static ver 1.56.x | 4.1.87.Final | 2.0.61.Final 1.57.x-1.58.x | 4.1.93.Final | 2.0.61.Final 1.59.x | 4.1.97.Final | 2.0.61.Final -1.60.x-1.65.x | 4.1.100.Final | 2.0.61.Final -1.66.x | 4.1.110.Final | 2.0.65.Final +1.60.x-1.66.x | 4.1.100.Final | 2.0.61.Final +1.67.x | 4.1.110.Final | 2.0.65.Final _(grpc-netty-shaded avoids issues with keeping these versions in sync.)_ From 50362bdcebfec460f9249a511d4bc45132375a88 Mon Sep 17 00:00:00 2001 From: Kannan J Date: Tue, 6 Aug 2024 14:26:00 +0000 Subject: [PATCH 6/6] Fix versions in libs.versions.toml --- gradle/libs.versions.toml | 4 ++-- .../src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 78550e9c95e..299ca60ab4b 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,8 +1,8 @@ [versions] -netty = '4.1.100.Final' +netty = '4.1.110.Final' # Keep the following references of tcnative version in sync whenever it's updated: # SECURITY.md -nettytcnative = '2.0.61.Final' +nettytcnative = '2.0.65.Final' opencensus = "0.31.1" # Not upgrading to 4.x as it is not yet ABI compatible. # https://github.com/protocolbuffers/protobuf/issues/17247 diff --git a/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java b/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java index 7a5e4b43c8b..89803998925 100644 --- a/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java +++ b/netty/shaded/src/testShadow/java/io/grpc/netty/shaded/ShadingTest.java @@ -79,7 +79,7 @@ public void nettyResourcesUpdated() throws IOException { InputStream inputStream = NettyChannelBuilder.class.getClassLoader() .getResourceAsStream( "META-INF/native-image/io.grpc.netty.shaded.io.netty/netty-transport/" - + "reflection-config.json"); + + "reflect-config.json"); assertThat(inputStream).isNotNull(); Scanner s = new Scanner(inputStream, StandardCharsets.UTF_8.name()).useDelimiter("\\A");