-
Notifications
You must be signed in to change notification settings - Fork 241
Update Netty to 4.2.10.Final #779
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
c8ecfab
db69acb
25cb4c3
dc05726
1e1ba54
4394238
50250d5
b05b9e0
5356e2e
58f5038
9c01df9
c99df96
990805c
142f009
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,18 @@ | ||
| ### Unreleased | ||
|
|
||
| * BREAKING: Bump Netty to 4.2.10.Final | ||
| * Promote io_uring transport from incubator (`io.netty.incubator` → `io.netty`) | ||
| * Load io_uring transport classes lazily via reflection (requires Java 9+; gracefully unavailable on Java 8) | ||
| * Add kqueue `osx-aarch_64` native transport for Apple Silicon | ||
| * Update `self-signed-ssl-context` for JDK 24+ compatibility via Netty `CertificateBuilder`, with `SelfSignedCertificate` fallback | ||
| * Fix deprecated `Class.newInstance()` usage in `CertificateBuilder` reflection (use `Constructor.newInstance()`) | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. No need to mention a fix for something that was never released. |
||
| * Remove deprecated `ChannelOption/MAX_MESSAGES_PER_READ` usage | ||
| * Fix HTTP/2 connection preface not flushed on already-active pipelines (affected JDK 21 with unpooled allocator) | ||
|
|
||
| Contributions by (in alphabetical order): | ||
|
|
||
| Robin Lahtinen | ||
|
|
||
| ### 0.9.5 | ||
|
|
||
| * Fix NPE in `wrap-exceptions` HTTP client middleware (#766, #767) | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| ;; you'll need to run the script at `deps/lein-to-deps` after changing any dependencies | ||
| (def netty-version "4.1.130.Final") | ||
| (def netty-version "4.2.10.Final") | ||
| (def brotli-version "1.20.0") | ||
|
|
||
|
|
||
|
|
@@ -18,16 +18,19 @@ | |
| [io.netty/netty-transport-native-epoll ~netty-version :classifier "linux-x86_64"] | ||
| [io.netty/netty-transport-native-epoll ~netty-version :classifier "linux-aarch_64"] | ||
| [io.netty/netty-transport-native-kqueue ~netty-version :classifier "osx-x86_64"] | ||
| [io.netty.incubator/netty-incubator-transport-native-io_uring "0.0.26.Final" :classifier "linux-x86_64"] | ||
| [io.netty.incubator/netty-incubator-transport-native-io_uring "0.0.26.Final" :classifier "linux-aarch_64"] | ||
| [io.netty/netty-codec ~netty-version] | ||
| [io.netty/netty-transport-native-kqueue ~netty-version :classifier "osx-aarch_64"] | ||
| [io.netty/netty-transport-native-io_uring ~netty-version :classifier "linux-x86_64"] | ||
| [io.netty/netty-transport-native-io_uring ~netty-version :classifier "linux-aarch_64"] | ||
| [io.netty/netty-codec-http ~netty-version] | ||
| [io.netty/netty-codec-http2 ~netty-version] | ||
| [io.netty/netty-codec-compression ~netty-version] | ||
| [io.netty/netty-handler ~netty-version] | ||
| [io.netty/netty-handler-proxy ~netty-version] | ||
| [io.netty/netty-resolver ~netty-version] | ||
| [io.netty/netty-resolver-dns ~netty-version] | ||
| [metosin/malli "0.20.0" :exclusions [org.clojure/clojure]]] | ||
| :exclusions [org.bouncycastle/bcprov-jdk15on | ||
| org.bouncycastle/bcpkix-jdk15on] | ||
| :profiles {:dev {:dependencies [[criterium "0.4.6"] | ||
| [cheshire "6.1.0"] | ||
| [org.slf4j/slf4j-simple "2.0.17"] | ||
|
|
@@ -37,7 +40,8 @@ | |
| [org.bouncycastle/bcprov-jdk18on "1.83"] | ||
| [org.bouncycastle/bcpkix-jdk18on "1.83" :exclusions [org.bouncycastle/bcutil-jdk18on]] | ||
| ;;[org.bouncycastle/bctls-jdk18on "1.75"] | ||
| [io.netty/netty-tcnative-boringssl-static "2.0.74.Final"] | ||
| [io.netty/netty-tcnative-boringssl-static "2.0.75.Final"] | ||
| [io.netty/netty-pkitesting ~netty-version] | ||
| ;;[com.aayushatharva.brotli4j/all ~brotli-version] | ||
| [com.aayushatharva.brotli4j/brotli4j ~brotli-version] | ||
| [com.aayushatharva.brotli4j/service ~brotli-version] | ||
|
|
@@ -66,6 +70,8 @@ | |
| "-Dio.netty.allocator.type=unpooled"]} | ||
| :dropped-error-deferred-detection {:jvm-opts ["-Dorg.slf4j.simpleLogger.log.manifold.debug=warn" | ||
| "-Daleph.testutils.detect-dropped-error-deferreds=true"]} | ||
| :test-unsafe-deny {:jvm-opts ["--sun-misc-unsafe-memory-access=deny"]} | ||
| :jdk-21 {:javac-options ^:replace ["--release" "11"]} | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What's the reason for this? |
||
| :pedantic {:pedantic? :abort} | ||
| :trace {:jvm-opts ["-Dorg.slf4j.simpleLogger.defaultLogLevel=trace"]} | ||
| :profile {:dependencies [[com.clojure-goes-fast/clj-async-profiler "1.7.0"]] | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1399,6 +1399,21 @@ | |
| true | ||
| http2-conn-pipeline-transform) | ||
|
|
||
| ;; Flush the HTTP/2 connection preface (magic + initial SETTINGS) that was | ||
| ;; written by Http2ConnectionHandler.sendPreface() during handlerAdded. | ||
| ;; When Http2FrameCodec is added to an already-active pipeline (the normal | ||
| ;; case for both client post-SSL-handshake and server ALPN paths), | ||
| ;; channelActive is never replayed, so the flushPreface guard in | ||
| ;; PrefaceDecoder.channelActive never fires. Without this explicit flush, | ||
| ;; the preface sits in SslHandler.pendingUnencryptedWrites and under | ||
| ;; certain allocator/timing conditions (e.g., unpooled allocator on | ||
| ;; JDK 21), a SETTINGS ACK can be flushed before the initial SETTINGS, | ||
| ;; causing the peer to reject the connection. | ||
| ;; See https://github.com/netty/netty/issues/12089 | ||
| (let [ch (.channel pipeline)] | ||
| (when (.isActive ch) | ||
| (.flush ch))) | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hm, how did you figure this out and are you sure this is indeed a possible explanation? FYI: I've shared this with Netty upstream and they are not convinced so far 🤔 Note that we have #772 to track this particular issue. |
||
|
|
||
| (log/debug "Conn chan pipeline:" pipeline) | ||
|
|
||
| pipeline)) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah very good, updating the CI pipeline to use more recent versions was on my radar, as well. Ideally, we'd use matrix jobs for testing combinations of supported Clojure and JDK versions but we can do that in a follow-up. Filed #780 as a placeholder.