diff options
author | Bjørn Christian Seime <bjorncs@verizonmedia.com> | 2019-07-26 12:53:20 +0200 |
---|---|---|
committer | Bjørn Christian Seime <bjorncs@verizonmedia.com> | 2019-07-26 12:53:20 +0200 |
commit | b2eb211c65ef3d6b059b752a3a034027ee9e81b6 (patch) | |
tree | ed9ba656dc44e9f36e8030f81fb3879a4ced1c93 /vespa-http-client | |
parent | 01e8858da21c70e387ebd1f1f04b04deb4c43e58 (diff) |
Duration.toSeconds() is only available on Java 9+
Diffstat (limited to 'vespa-http-client')
-rw-r--r-- | vespa-http-client/src/main/java/com/yahoo/vespa/http/client/core/communication/ApacheGatewayConnection.java | 2 |
1 files changed, 1 insertions, 1 deletions
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 77a18b631ee..00f52d6337f 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 @@ -406,7 +406,7 @@ class ApacheGatewayConnection implements GatewayConnection { } clientBuilder.setMaxConnPerRoute(1); clientBuilder.setMaxConnTotal(1); - clientBuilder.setConnectionTimeToLive(connectionParams.getConnectionTimeToLive().toSeconds(), TimeUnit.SECONDS); + clientBuilder.setConnectionTimeToLive(connectionParams.getConnectionTimeToLive().getSeconds(), TimeUnit.SECONDS); clientBuilder.setUserAgent(String.format("vespa-http-client (%s)", Vtag.currentVersion)); clientBuilder.setDefaultHeaders(Collections.singletonList(new BasicHeader(Headers.CLIENT_VERSION, Vtag.currentVersion))); clientBuilder.disableContentCompression(); |