Bug report Returning more data (bytes) than provided with ContentLength header for HTTP GET causes that next request is corrupted. The behaviour showed up with 3.3.3 version - on 3.3.2 and previous ones worked fine.

Simplest reproduction can be found here: https://github.com/ArkadiuszKalinowski/web-test-client-issue. Second request in the endpointTest() is causing: org.springframework.web.reactive.function.client.WebClientRequestException: invalid version format: 123HTTP/1.1

Spring boot 3.3.3

Comment From: bclozel

I think this is the expected behavior for any HTTP connection with a connection pool. The HTTP client will only read up to the declared content-length; if the connection is not closed, the client will read from the connection for the next exchange.

I would say the initial premise of this issue is wrong and such problems are expected as a result.