Skip to content

Commit 50dd4b8

Browse files
committed
Switch to Netty 4.2
Signed-off-by: Andriy Redko <[email protected]>
1 parent 4aff917 commit 50dd4b8

File tree

151 files changed

+243
-282
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

151 files changed

+243
-282
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions

buildSrc/src/main/java/org/opensearch/gradle/OpenSearchTestBasePlugin.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,8 @@ public void execute(Task t) {
201201
test.systemProperty("io.netty.noUnsafe", "true");
202202
test.systemProperty("io.netty.noKeySetOptimization", "true");
203203
test.systemProperty("io.netty.recycler.maxCapacityPerThread", "0");
204+
// See please https://github.com/netty/netty/issues/15631
205+
test.systemProperty("io.netty.allocator.type", "pooled");
204206

205207
test.testLogging(logging -> {
206208
logging.setShowExceptions(true);

client/rest/licenses/reactor-core-3.7.5.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
6a1a5c00b8df0fe4663c2c705e1ed00a5a9fe8ff

distribution/src/config/jvm.options

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,3 +86,6 @@ ${error.file}
8686

8787
21-:-javaagent:agent/opensearch-agent.jar
8888
21-:--add-opens=java.base/java.nio=org.apache.arrow.memory.core,ALL-UNNAMED
89+
90+
// See please https://github.com/netty/netty/issues/1563
91+
-Dio.netty.allocator.type=pooled

gradle/libs.versions.toml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,13 @@ json_smart = "2.5.2"
3333
# when updating the JNA version, also update the version in buildSrc/build.gradle
3434
jna = "5.16.0"
3535

36-
netty = "4.1.124.Final"
36+
netty = "4.2.5.Final"
3737
joda = "2.12.7"
3838
roaringbitmap = "1.3.0"
3939

4040
# project reactor
41-
reactor_netty = "1.2.9"
42-
reactor = "3.7.5"
41+
reactor_netty = "1.3.0-M6"
42+
reactor = "3.8.0-M6"
4343

4444
# client dependencies
4545
httpclient5 = "5.4.4"
@@ -137,9 +137,12 @@ lucene-spatial3d = { group = "org.apache.lucene", name = "lucene-spatial3d", ver
137137
lucene-suggest = { group = "org.apache.lucene", name = "lucene-suggest", version.ref = "lucene" }
138138
netty-buffer = { group = "io.netty", name = "netty-buffer", version.ref = "netty" }
139139
netty-codec = { group = "io.netty", name = "netty-codec", version.ref = "netty" }
140+
netty-codec-base = { group = "io.netty", name = "netty-codec-base", version.ref = "netty" }
141+
netty-codec-compression = { group = "io.netty", name = "netty-codec-compression", version.ref = "netty" }
140142
netty-codec-dns = { group = "io.netty", name = "netty-codec-dns", version.ref = "netty" }
141143
netty-codec-http = { group = "io.netty", name = "netty-codec-http", version.ref = "netty" }
142144
netty-codec-http2 = { group = "io.netty", name = "netty-codec-http2", version.ref = "netty" }
145+
netty-codec-http3 = { group = "io.netty", name = "netty-codec-http3", version.ref = "netty" }
143146
netty-common = { group = "io.netty", name = "netty-common", version.ref = "netty" }
144147
netty-handler = { group = "io.netty", name = "netty-handler", version.ref = "netty" }
145148
netty-resolver-dns = { group = "io.netty", name = "netty-resolver-dns", version.ref = "netty" }
@@ -184,7 +187,9 @@ lucene = [
184187

185188
netty = [
186189
"netty-buffer",
190+
"netty-codec-base",
187191
"netty-codec",
192+
"netty-codec-compression",
188193
"netty-codec-dns",
189194
"netty-codec-http",
190195
"netty-codec-http2",

modules/transport-netty4/build.gradle

Lines changed: 21 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ opensearchplugin {
5757
dependencies {
5858
// network stack
5959
api "io.netty:netty-buffer:${versions.netty}"
60+
api "io.netty:netty-codec-base:${versions.netty}"
61+
api "io.netty:netty-codec-compression:${versions.netty}"
6062
api "io.netty:netty-codec:${versions.netty}"
6163
api "io.netty:netty-codec-http:${versions.netty}"
6264
api "io.netty:netty-codec-http2:${versions.netty}"
@@ -158,34 +160,13 @@ thirdPartyAudit {
158160
'org.bouncycastle.openssl.jcajce.JcePEMDecryptorProviderBuilder',
159161
'org.bouncycastle.pkcs.PKCS8EncryptedPrivateKeyInfo',
160162

161-
// from io.netty.handler.ssl.JettyNpnSslEngine (netty)
162-
'org.eclipse.jetty.npn.NextProtoNego$ClientProvider',
163-
'org.eclipse.jetty.npn.NextProtoNego$ServerProvider',
164-
'org.eclipse.jetty.npn.NextProtoNego',
165-
166-
// from io.netty.handler.codec.marshalling.ChannelBufferByteInput (netty)
167-
'org.jboss.marshalling.ByteInput',
168-
169-
// from io.netty.handler.codec.marshalling.ChannelBufferByteOutput (netty)
170-
'org.jboss.marshalling.ByteOutput',
171-
172-
// from io.netty.handler.codec.marshalling.CompatibleMarshallingEncoder (netty)
173-
'org.jboss.marshalling.Marshaller',
174-
175-
// from io.netty.handler.codec.marshalling.ContextBoundUnmarshallerProvider (netty)
176-
'org.jboss.marshalling.MarshallerFactory',
177-
'org.jboss.marshalling.MarshallingConfiguration',
178-
'org.jboss.marshalling.Unmarshaller',
179-
180163
// from io.netty.util.internal.logging.InternalLoggerFactory (netty) - it's optional
181164
'org.slf4j.helpers.FormattingTuple',
182165
'org.slf4j.helpers.MessageFormatter',
183166
'org.slf4j.Logger',
184167
'org.slf4j.LoggerFactory',
185168
'org.slf4j.spi.LocationAwareLogger',
186169

187-
'com.google.protobuf.nano.CodedOutputByteBufferNano',
188-
'com.google.protobuf.nano.MessageNano',
189170
'com.ning.compress.BufferRecycler',
190171
'com.ning.compress.lzf.ChunkDecoder',
191172
'com.ning.compress.lzf.ChunkEncoder',
@@ -209,26 +190,38 @@ thirdPartyAudit {
209190
'io.netty.internal.tcnative.SSL',
210191
'io.netty.internal.tcnative.SSLSession',
211192
'io.netty.internal.tcnative.SSLSessionCache',
212-
'org.eclipse.jetty.alpn.ALPN$ClientProvider',
213-
'org.eclipse.jetty.alpn.ALPN$ServerProvider',
214-
'org.eclipse.jetty.alpn.ALPN',
215193

216194
'org.conscrypt.AllocatedBuffer',
217195
'org.conscrypt.BufferAllocator',
218196
'org.conscrypt.Conscrypt',
219197
'org.conscrypt.HandshakeListener',
220198

221199
'reactor.blockhound.BlockHound$Builder',
222-
'reactor.blockhound.integration.BlockHoundIntegration'
200+
'reactor.blockhound.integration.BlockHoundIntegration',
201+
202+
'io.netty.pkitesting.CertificateBuilder',
203+
'io.netty.pkitesting.CertificateBuilder$Algorithm',
204+
'io.netty.pkitesting.X509Bundle'
223205
)
224206

225207
ignoreViolations(
208+
'io.netty.buffer.AbstractAllocatorEvent',
209+
'io.netty.buffer.AbstractBufferEvent',
210+
'io.netty.buffer.AbstractChunkEvent',
211+
'io.netty.buffer.AdaptivePoolingAllocator$AdaptiveByteBuf',
212+
'io.netty.buffer.AdaptivePoolingAllocator$Chunk',
213+
'io.netty.buffer.AllocateBufferEvent',
214+
'io.netty.buffer.AllocateChunkEvent',
215+
'io.netty.buffer.FreeBufferEvent',
216+
'io.netty.buffer.FreeChunkEvent',
217+
'io.netty.buffer.PooledByteBufAllocator',
218+
'io.netty.buffer.ReallocateBufferEvent',
219+
'io.netty.buffer.ReturnChunkEvent',
226220
'io.netty.util.internal.PlatformDependent0',
227221
'io.netty.util.internal.PlatformDependent0$1',
228222
'io.netty.util.internal.PlatformDependent0$2',
229223
'io.netty.util.internal.PlatformDependent0$3',
230-
'io.netty.util.internal.PlatformDependent0$4',
231-
'io.netty.util.internal.PlatformDependent0$6',
224+
'io.netty.util.internal.PlatformDependent0$5',
232225
'io.netty.util.internal.shaded.org.jctools.queues.BaseLinkedQueueConsumerNodeRef',
233226
'io.netty.util.internal.shaded.org.jctools.queues.BaseLinkedQueueProducerNodeRef',
234227
'io.netty.util.internal.shaded.org.jctools.queues.BaseMpscLinkedArrayQueueColdProducerFields',
@@ -245,12 +238,6 @@ thirdPartyAudit {
245238
'io.netty.util.internal.shaded.org.jctools.queues.unpadded.MpscUnpaddedArrayQueueProducerLimitField',
246239
'io.netty.util.internal.shaded.org.jctools.util.UnsafeAccess',
247240
'io.netty.util.internal.shaded.org.jctools.util.UnsafeRefArrayAccess',
248-
'io.netty.util.internal.shaded.org.jctools.util.UnsafeLongArrayAccess',
249-
'io.netty.handler.ssl.util.OpenJdkSelfSignedCertGenerator',
250-
'io.netty.handler.ssl.util.OpenJdkSelfSignedCertGenerator$1',
251-
'io.netty.handler.ssl.util.OpenJdkSelfSignedCertGenerator$2',
252-
'io.netty.handler.ssl.util.OpenJdkSelfSignedCertGenerator$3',
253-
'io.netty.handler.ssl.util.OpenJdkSelfSignedCertGenerator$4',
254-
'io.netty.handler.ssl.util.OpenJdkSelfSignedCertGenerator$5'
241+
'io.netty.util.internal.shaded.org.jctools.util.UnsafeLongArrayAccess'
255242
)
256243
}

modules/transport-netty4/licenses/netty-buffer-4.1.124.Final.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ec2a90c9909190759c0e4a6101efae52a7947ada

modules/transport-netty4/licenses/netty-codec-4.1.124.Final.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)