You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I debugged in the logic code and found that the connection timeout from new class HttpComponents5MessageSender will passed to HttpComponents5ClientFactory. And based on the HttpComponents5ClientFactory doc page, the function setConnectionTimeout should be "Sets the timeout until a connection is established."
However, when dig dive into the logic code, I found that the first logic implement for HttpComponents5ClientFactory is implement as expected when set the connectTimeout for RequestConfig at here, at this issue.
But on the version v4.0.5, and at this commit, the function setConnectTimeout is replaced by setConnectionRequestTimeout.
However, the 2 function are not the same:
setConnectionRequestTimeout: the connection lease request timeout used when requesting a connection from the connection manager.
setConnectTimeout: Determines the timeout until a new connection is fully established. This may also include transport security negotiation exchanges such as SSL or TLS protocol negotiation).
The result is the connect timeout is not working as expected when migrating from HttpComponentsMessageSender to HttpComponents5MessageSender and keeping both functions setConnectionTimeout, setReadTimeout. And the connect timeout will default to 2 minutes despite a specific configuration for HttpComponents5MessageSender.setConnectionTimeout
The text was updated successfully, but these errors were encountered:
phuc98ute
changed the title
Establish connect timeout to remote server is not work with HttpComponents5ClientFactory
Establish connect timeout to remote server is not work with HttpComponents5MessageSender
Oct 16, 2024
corneil
pushed a commit
to corneil/spring-ws
that referenced
this issue
Nov 4, 2024
This was changed by accident in 4c5bd74. However, this isn't a regression as it's an new class that was shipped in 4.0.5 and was this way from the get-go.
snicoll
changed the title
Establish connect timeout to remote server is not work with HttpComponents5MessageSender
Connection timeout in HttpComponents5MessageSender is not respected
Mar 11, 2025
Hi team,
I am trying to use a new class HttpComponents5MessageSender instead old class HttpComponentsMessageSender this have the same 2 functions: setConnectionTimeout and setReadTimeout
I debugged in the logic code and found that the connection timeout from new class HttpComponents5MessageSender will passed to HttpComponents5ClientFactory. And based on the HttpComponents5ClientFactory doc page, the function setConnectionTimeout should be "Sets the timeout until a connection is established."

However, when dig dive into the logic code, I found that the first logic implement for HttpComponents5ClientFactory is implement as expected when set the connectTimeout for RequestConfig at here, at this issue.
But on the version v4.0.5, and at this commit, the function setConnectTimeout is replaced by setConnectionRequestTimeout.
However, the 2 function are not the same:
The result is the connect timeout is not working as expected when migrating from HttpComponentsMessageSender to HttpComponents5MessageSender and keeping both functions setConnectionTimeout, setReadTimeout. And the connect timeout will default to 2 minutes despite a specific configuration for HttpComponents5MessageSender.setConnectionTimeout
The text was updated successfully, but these errors were encountered: