44
55import java .io .IOException ;
66import java .net .URI ;
7- import java .util .concurrent .TimeUnit ;
87
98import javax .net .ssl .SSLContext ;
109import javax .ws .rs .client .Client ;
1110import javax .ws .rs .client .ClientBuilder ;
1211import javax .ws .rs .client .WebTarget ;
1312
14- import org .apache .http .client .config .RequestConfig ;
1513import org .apache .http .config .RegistryBuilder ;
1614import org .apache .http .conn .socket .ConnectionSocketFactory ;
1715import org .apache .http .conn .socket .PlainConnectionSocketFactory ;
@@ -120,7 +118,7 @@ public void init(DockerClientConfig dockerClientConfig) {
120118 }
121119
122120 PoolingHttpClientConnectionManager connManager = new PoolingHttpClientConnectionManager (getSchemeRegistry (
123- originalUri , sslContext ), null , null , null , 10 , TimeUnit . SECONDS );
121+ originalUri , sslContext ));
124122
125123 if (dockerClientConfig .getMaxTotalConnections () != null )
126124 connManager .setMaxTotal (dockerClientConfig .getMaxTotalConnections ());
@@ -129,8 +127,9 @@ public void init(DockerClientConfig dockerClientConfig) {
129127
130128 clientConfig .property (ApacheClientProperties .CONNECTION_MANAGER , connManager );
131129
132- clientConfig .property (ApacheClientProperties .REQUEST_CONFIG , RequestConfig .custom ()
133- .setConnectionRequestTimeout (1000 ).build ());
130+ // Configure connection pool timeout
131+ // clientConfig.property(ApacheClientProperties.REQUEST_CONFIG, RequestConfig.custom()
132+ // .setConnectionRequestTimeout(1000).build());
134133
135134 ClientBuilder clientBuilder = ClientBuilder .newBuilder ().withConfig (clientConfig );
136135
0 commit comments