Enhance visibility of connection handshake process - #161
Merged
Conversation
Baraujo25
approved these changes
Aug 21, 2026
Collaborator
Author
|
@copilot resolve the merge conflicts in this pull request |
Co-authored-by: 3dgiordano <797057+3dgiordano@users.noreply.github.com>
Resolved by merging |
Collaborator
Author
|
@copilot resolve the merge conflicts in this pull request |
Co-authored-by: 3dgiordano <797057+3dgiordano@users.noreply.github.com>
Co-authored-by: 3dgiordano <797057+3dgiordano@users.noreply.github.com>
Resolved by merging the latest |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a mechanism to capture and report all connection attempts and their failures when establishing HTTP connections using Jetty, instead of only reporting the last failed attempt. This improves diagnostics for failed samples by attaching suppressed exceptions for each failed address, making connection issues more transparent in test results. The implementation involves a new
ConnectAttemptRecorderclass, integration of this recorder into all relevant HTTP client transports, and changes in the sampler to include these details in the error reporting.The most important changes are:
Connection Failure Recording:
ConnectAttemptRecorderthat tracks all connection failures for each attempted address, and attaches them as suppressed exceptions to the main failure for improved error diagnostics. (src/main/java/com/blazemeter/jmeter/http2/core/ConnectAttemptRecorder.java)Integration with HTTP Client Transports:
Introduced
RecordingHttpClientTransportDynamic(a subclass ofHttpClientTransportDynamic) and updated all HTTP client instantiations inHTTP2JettyClientto use this subclass, ensuring that every connection attempt is recorded. (src/main/java/com/blazemeter/jmeter/http2/core/HTTP2JettyClient.java) [1] [2] [3] [4] [5] [6]Modified
CustomHttpClientTransportOverHTTP2to accept and leverage theConnectAttemptRecorder, ensuring connection attempts are also tracked for HTTP/2 prior knowledge connections. (src/main/java/com/blazemeter/jmeter/http2/core/jetty/custom/http2/CustomHttpClientTransportOverHTTP2.java) [1] [2]Sampler Error Reporting:
HTTP2Samplerto call a new methodattachConnectAttempts, which adds all recorded connection failures as suppressed exceptions to the thrown error, so they appear in the JMeter View Results Tree. (src/main/java/com/blazemeter/jmeter/http2/sampler/HTTP2Sampler.java)API for Attaching Attempts:
attachConnectAttemptstoHTTP2JettyClientto expose the connection attempt recording for use by the sampler. (src/main/java/com/blazemeter/jmeter/http2/core/HTTP2JettyClient.java)These changes collectively enhance the observability of connection issues by providing a complete picture of all attempted addresses and their respective failures during HTTP client operations.