Merge pull request #38591 from tomfrenken

* pr/38591:
  Use system properties when constructing Apache HttpClient

Closes gh-38591
This commit is contained in:
Moritz Halbritter 2023-11-29 13:59:46 +01:00
commit ae0ae8234f

View File

@ -190,7 +190,8 @@ public final class ClientHttpRequestFactories {
options.getEnabledProtocols(), options.getCiphers(), new DefaultHostnameVerifier());
connectionManagerBuilder.setSSLSocketFactory(socketFactory);
}
PoolingHttpClientConnectionManager connectionManager = connectionManagerBuilder.build();
PoolingHttpClientConnectionManager connectionManager = connectionManagerBuilder.useSystemProperties()
.build();
return HttpClientBuilder.create().useSystemProperties().setConnectionManager(connectionManager).build();
}