On Tue, 30 Sep 2025 17:34:43 GMT, Volkan Yazici <[email protected]> wrote:
>> Currently `HttpRequest::timeout` only applies until the response headers are
>> received. Extend its scope to also cover the consumption of the response
>> body.
>>
>> ### Review guidelines
>>
>> 1. Read _"the fix"_ in `MultiExchange`
>> 2. Skim through the test server *handler* in `TimeoutResponseTestSupport`
>> 3. Review first `TimeoutResponseHeaderTest`, and then
>> `TimeoutResponseBodyTest` (Mind the multiple `@test` blocks!)
>
> src/java.net.http/share/classes/jdk/internal/net/http/Http3ExchangeImpl.java
> line 1341:
>
>> 1339: if (!responseReceived && resetError ==
>> Http3Error.H3_REQUEST_REJECTED) {
>> 1340: exchange.markUnprocessedByPeer();
>> 1341: }
>
> Without this, server handler's
> `exchange.resetStream(Http3Error.H3_REQUEST_REJECTED.code())` results in
> client to fail the request, instead of retrying it. I am not sure if
> `H3_REQUEST_REJECTED` is the only error code we should guard against.
Figured the problem is more convoluted than it appears. @jaikiran will soon
land a PR adressing this issue. I will hold this PR until then.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27469#discussion_r2407905198