Skip to content

Conversation

@danielkec
Copy link
Contributor

Fixes #10820

@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Nov 7, 2025
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds thread-safety to HTTP/2 header processing in the client by synchronizing access to the shared inbound dynamic table across concurrent streams. The main changes include centralizing header reading logic and adding a test to verify correct behavior under concurrent stream multiplexing with many unique headers.

  • Introduced a thread-safe readHeaders method in Http2ClientConnection using ReentrantLock to protect the shared inbound dynamic table
  • Refactored Http2ClientStream.readHeaders to delegate to the connection-level method
  • Added a new test case multiplexParallelStreamsGetWithUniqueHeaders that exercises concurrent header processing with 1000 unique headers per stream

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
webclient/http2/src/main/java/io/helidon/webclient/http2/Http2ClientConnection.java Adds ReentrantLock for inbound dynamic table synchronization and introduces a new readHeaders method to centralize thread-safe header processing
webclient/http2/src/main/java/io/helidon/webclient/http2/Http2ClientStream.java Refactors header reading to use the new connection-level readHeaders method for thread-safe access to the dynamic table
webclient/http2/src/test/java/io/helidon/webclient/http2/Http2WebClientTest.java Adds new test endpoint and test method to verify concurrent header processing, includes copyright year update and code formatting improvements

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Signed-off-by: Daniel Kec <[email protected]>
@barchetta barchetta added this to the 4.3.2 milestone Nov 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

OCA Verified All contributors have signed the Oracle Contributor Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[4.x] RC in http2 client inbound dynamic table

2 participants