Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document HttpClient connection socket timeout behavior for CONNECT and SSL connections [SPR-16697] #21238

Closed
spring-projects-issues opened this issue Apr 6, 2018 · 0 comments
Assignees
Labels
type: documentation A documentation task type: enhancement A general enhancement
Milestone

Comments

@spring-projects-issues
Copy link
Collaborator

spring-projects-issues commented Apr 6, 2018

Brian Clozel opened SPR-16697 and commented

HttpComponentsClientHttpRequestFactory currently provides ways to customize different timeouts, including the setReadTimeout which sets the "socket read timeout" (in other words, the "maximum period inactivity between two consecutive data packets").

All of those are applied on the RequestConfig, which is effective only "once connection route has been fully established" (see HTTPCLIENT-1892). In case of HTTP requests that require first a SSL handshake or a CONNECT request to a proxy, the RequestConfig does not apply on the time spent waiting for a socket at that point.

This has to be configured at the HttpClient level itself, using the default SocketConfig or even configuring finer options on the connection manager itself (connection pooling behavior, per-host configuration, etc).

This clearly isn't the goal of the HttpComponentsClientHttpRequestFactory and should be dealt with using directly the HttpClient builder API.

This issue is about documenting this fact on the setConnectTimeout method.


Affects: 5.0.5

Reference URL: spring-projects/spring-boot#11379

Issue Links:

Referenced from: commits 2dde000

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: documentation A documentation task type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants