[improve][build] Upgrade async-http-client to 3.0.13 and netty-reactive-streams to 2.0.19 - #26366
[improve][build] Upgrade async-http-client to 3.0.13 and netty-reactive-streams to 2.0.19#26366lhotari wants to merge 2 commits into
Conversation
…ve-streams to 2.0.19 - async-http-client 3.0.10 -> 3.0.13 - netty-reactive-streams 2.0.6 -> 2.0.19 These two form the HTTP stack behind the admin client. They were originally part of the networking dependency update (apache#26358) and are split out here because that PR reproducibly failed four integration and system test jobs, and these are the most likely trigger. The failure mode is that pulsar-admin / pulsar-client print a JDK restricted-method warning to stderr: WARNING: java.lang.System::loadLibrary has been called by io.netty.util.internal.NativeLibraryUtil in an unnamed module (file:/pulsar/lib/io.netty-netty-common-4.2.17.Final.jar) Tests that assert the CLI produces no stderr output then fail. Netty itself is not changed by this PR, and the server distribution's jar list is identical apart from these two version bumps, so the trigger is a change in when a Netty native library gets loaded rather than which Netty is used. Note that bin/pulsar passes --enable-native-access=ALL-UNNAMED but bin/pulsar-admin-common.sh does not, which is why the warning is only visible from the CLI; that gap is addressed separately. Splitting this out lets CI confirm whether these two libraries are in fact the trigger, while the rest of the networking updates proceed independently. Assisted-by: Claude Code (Opus 5)
|
Update: the mechanism is now confirmed from the async-http-client sources, so this is no longer a hypothesis.
3.0.10 if (config.isUseNativeTransport()) {
transportFactory = getNativeTransportFactory(config);
} else {
transportFactory = NioTransportFactory.INSTANCE;
}3.0.13 if (config.isUseNativeTransport()) {
transportFactory = getNativeTransportFactory(config);
} else {
transportFactory = autoSelectTransportFactory();
}
// Default when useNativeTransport is unset: native transport if its lib is on the classpath (silently),
// else NIO. Use -Dio.netty.transport.noNative=true to force NIO.It calls So with Why only the CLI is affected: This is a behaviour change rather than a defect: preferring native transport is a reasonable default, For completeness, two AHC settings that might look like alternatives but are not:
|
…y-reactive # Conflicts: # distribution/shell/src/assemble/LICENSE.bin.txt # gradle/libs.versions.toml
Motivation
async-http-clientandnetty-reactive-streamsare the HTTP stack behind the admin client.They were originally part of #26358 (networking dependency updates) and are split out here,
because that PR reproducibly failed four integration and system test jobs and these two are the
most likely trigger.
Modifications
gradle/libs.versions.toml:Plus the corresponding jar names in the server and shell distribution
LICENSE.bin.txtfiles.Why these are split out — what CI showed
On #26358 the following jobs failed, twice, identically (master and the twelve sibling
dependency PRs were green):
All four share one root cause.
pulsar-admin/pulsar-clientprint a JDK restricted-methodwarning to stderr, and the tests assert the CLI produces no stderr output:
What was ruled out while diagnosing this:
apache-pulsar-*-bin.tar.gzjar listagainst the base commit shows only the intended version bumps. No new Netty jars appear, and
netty-transport-native-epoll/-io_uringare present in both.ahc-default.propertieshasuseNativeTransport=falseanduseOnlyEpollNativeTransport=falsein both 3.0.10 and 3.0.13.So the trigger is a change in when a Netty native library is loaded, not in which Netty is
used. AHC 3.0.13 does add DNS/IP-cooldown behaviour (
failedIpCooldownEnabled,loadBalance) that 3.0.10 lacks, which is a plausible path to an availability probe such asIoUring.isAvailable()loading the native library, but this PR does not claim that as proven —it exists so CI can confirm or refute it in isolation.
Related:
bin/pulsarpasses--enable-native-access=ALL-UNNAMEDwhilebin/pulsar-admin-common.shdoes not, which is why the warning is only visible from the CLI.That gap is a pre-existing issue and is fixed separately in #26365.
Verifying this change
This change is already covered by existing tests — specifically the CLI, Function and
Connectors integration/system suites named above, which are exactly what this PR is meant to
exercise.
Verified locally with
./gradlew sanityCheckand./gradlew checkBinaryLicense.Does this pull request potentially affect one of the following parts: