Skip to content

Conversation

@sbordet
Copy link
Contributor

@sbordet sbordet commented Nov 5, 2025

The problem was that ALPNClientConnection, which is set up when using a HttpClientTransportDynamic with h1 and h2, does not properly override onIdleExpired().

Fixed by overriding onIdleExpired() and failing the connection promise, so that the error is reported to the application.

The problem was that ALPNClientConnection, which is set up when using a HttpClientTransportDynamic with h1 and h2, does not properly override onIdleExpired().

Fixed by overriding onIdleExpired() and failing the connection promise, so that the error is reported to the application.

Signed-off-by: Simone Bordet <[email protected]>
@sbordet sbordet requested a review from lorban November 5, 2025 13:32
@sbordet sbordet self-assigned this Nov 5, 2025
@sbordet sbordet moved this to 👀 In review in Jetty 12.1.4 - FROZEN Nov 5, 2025
@sbordet sbordet linked an issue Nov 5, 2025 that may be closed by this pull request
@olamy
Copy link
Member

olamy commented Nov 6, 2025

failing for me locally as well

[INFO] 
[ERROR] Failures: 
[ERROR] org.eclipse.jetty.test.client.transport.HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections(String, String)[2]
[ERROR]   Run 1: HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections:822 Unexpected exception type thrown, expected: <java.util.concurrent.TimeoutException> but was: <java.util.concurrent.ExecutionException>
[ERROR]   Run 2: HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections:822 Unexpected exception type thrown, expected: <java.util.concurrent.TimeoutException> but was: <java.util.concurrent.ExecutionException>
[INFO] 
[ERROR] org.eclipse.jetty.test.client.transport.HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections(String, String)[5]
[ERROR]   Run 1: HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections:822 Unexpected exception type thrown, expected: <java.util.concurrent.TimeoutException> but was: <java.util.concurrent.ExecutionException>
[ERROR]   Run 2: HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections:822 Unexpected exception type thrown, expected: <java.util.concurrent.TimeoutException> but was: <java.util.concurrent.ExecutionException>
[INFO] 
[ERROR] org.eclipse.jetty.test.client.transport.HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections(String, String)[6]
[ERROR]   Run 1: HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections:822 Unexpected exception type thrown, expected: <java.util.concurrent.TimeoutException> but was: <java.util.concurrent.ExecutionException>
[ERROR]   Run 2: HttpClientTransportDynamicTest.testServerDoesNotAcceptConnections:822 Unexpected exception type thrown, expected: <java.util.concurrent.TimeoutException> but was: <java.util.concurrent.ExecutionException>
[INFO] 
[WARNING] Flakes: 
[WARNING] org.eclipse.jetty.test.client.transport.HttpClientLoadTest.testConcurrent(TransportType)[5]
[ERROR]   Run 1: HttpClientLoadTest.testConcurrent:91
[INFO]   Run 2: PASS
[INFO] 
[INFO] 
[ERROR] Tests run: 976, Failures: 3, Errors: 0, Skipped: 18, Flakes: 1
[INFO] 

@olamy
Copy link
Member

olamy commented Nov 6, 2025

this is happening only with h2 test

In the case of h2, the cause is java.net.ConnectException

Easy fix would be to add if else instance of java.net.ConnectException but is it correct?

olamy and others added 7 commits November 6, 2025 19:42
)

#13976 allow configuring the default max local streams on the H2 client

Signed-off-by: Ludovic Orban <[email protected]>
* Fix #13883 handle logged null throwable
* Using fluent API


---------

Co-authored-by: Joakim Erdfelt <[email protected]>
… will perform the last write upon completion

Signed-off-by: Ludovic Orban <[email protected]>
@lorban lorban moved this to 👀 In review in Jetty 12.1.5 Nov 6, 2025
@lorban
Copy link
Contributor

lorban commented Nov 6, 2025

@olamy this wouldn't help. For some yet unknown reason, this test is flaky but the code change looks good.

@lorban
Copy link
Contributor

lorban commented Nov 10, 2025

@olamy we need to figure out why this test regularly fails in CI and your environment while it doesn't in mine.

I'm 99% sure the problem is in the test itself, but without being able to reproduce it, there isn't much I can do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: 👀 In review

Development

Successfully merging this pull request may close these issues.

HTTP/2 Client connection timeout does not work

7 participants