Skip to content

Commit

Permalink
Merge branch 'master' into NewClientMissingFeats
Browse files Browse the repository at this point in the history
  • Loading branch information
ohadbitt authored Nov 7, 2024
2 parents a2655c6 + afd44a7 commit 89f2a75
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ public static HttpClient create(HttpClientProperties properties) {

options.setMaximumConnectionPoolSize(properties.maxConnectionTotal());
options.setConnectionIdleTimeout(Duration.ofSeconds(properties.maxIdleTime()));
options.setResponseTimeout(properties.timeout());
options.setHttpClientProvider(properties.provider());

// Set Keep-Alive headers if they were requested.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public class HttpClientProperties {
private final boolean keepAlive;
private final Integer maxKeepAliveTime;
private final Integer maxConnectionTotal;
private final Duration timeout;
private final Integer maxConnectionRoute;
private final Class<? extends HttpClientProvider> provider;
private final ProxyOptions proxy;

Expand All @@ -22,7 +22,7 @@ private HttpClientProperties(HttpClientPropertiesBuilder builder) {
this.keepAlive = builder.keepAlive;
this.maxKeepAliveTime = builder.maxKeepAliveTime;
this.maxConnectionTotal = builder.maxConnectionsTotal;
this.timeout = builder.timeout;
this.maxConnectionRoute = builder.maxConnectionsPerRoute;
this.provider = builder.provider;
this.proxy = builder.proxy;
}
Expand Down Expand Up @@ -84,13 +84,12 @@ public Integer maxConnectionTotal() {
return maxConnectionTotal;
}

/**
* The default response timeout to apply to HTTP requests
* The maximum number of connections the client may keep open at the same time per route.
*
* @return the timeout
* @return the maximum number of connections per route
*/
public Duration timeout() {
return timeout;
public Integer maxConnectionRoute() {
return maxConnectionRoute;
}

/**
Expand Down

0 comments on commit 89f2a75

Please sign in to comment.