On Tue, 2026-01-06 at 08:46 -0500, Jonathan Amir wrote:
> Hello,
> I'm using http client 5.2.3, with CloseableHttpAsyncClient
> and PoolingAsyncClientConnectionManager. I am sending POST requests
> using
> SimpleHttpRequest and SimpleHttpResponse.
> Occasionally I catch a "java.net.SocketException Connection Reset"
> exception.
> When I retry my code to send another POST request after the
> exception, I
> hit the same Connection Reset exception again.
> I don't know how to analyze it, but it seems to me that on the second
> call
> the http client re-uses the same connection that previously
> encountered the
> Connection Reset exception, instead of using a new one.
> Is this possible, or am I missing something? If so, what can I do to
> ensure
> that the second call uses a valid connection?
> Is there a way to forcibly close/evict a connection from the pool if
> I
> think that it is bad?
> 
> Thanks,
> Jonathan

Hi Jonathan

Please make sure to upgrade to HttpClient 5.5.2 or 5.6. If you are
still able to reproduce the problem, please produce a context / wire of
the session exhibiting the problem as described here [1], raise a JIRA
ticket [2] and attach the log to it.

Oleg 

[1] https://hc.apache.org/httpcomponents-client-5.6.x/logging.html
[2]
https://hc.apache.org/httpcomponents-client-5.6.x/current/issue-management.html

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to