From 67e9162ccf16f96acb0dbefab200c979b5cb0962 Mon Sep 17 00:00:00 2001 From: Bjørn Christian Seime Date: Thu, 5 Dec 2019 17:13:18 +0100 Subject: Ensure connections are reused when client auth enabled --- .../vespa/http/client/core/communication/ApacheGatewayConnection.java | 1 + 1 file changed, 1 insertion(+) (limited to 'vespa-http-client') diff --git a/vespa-http-client/src/main/java/com/yahoo/vespa/http/client/core/communication/ApacheGatewayConnection.java b/vespa-http-client/src/main/java/com/yahoo/vespa/http/client/core/communication/ApacheGatewayConnection.java index 7aa451bd8db..e95044ce6d2 100644 --- a/vespa-http-client/src/main/java/com/yahoo/vespa/http/client/core/communication/ApacheGatewayConnection.java +++ b/vespa-http-client/src/main/java/com/yahoo/vespa/http/client/core/communication/ApacheGatewayConnection.java @@ -416,6 +416,7 @@ class ApacheGatewayConnection implements GatewayConnection { if (connectionParams.getHostnameVerifier() != null) { clientBuilder.setSSLHostnameVerifier(connectionParams.getHostnameVerifier()); } + clientBuilder.setUserTokenHandler(context -> null); // https://stackoverflow.com/a/42112034/1615280 } clientBuilder.setMaxConnPerRoute(1); clientBuilder.setMaxConnTotal(1); -- cgit v1.2.3