aboutsummaryrefslogtreecommitdiffstats
path: root/vespa-feed-client
diff options
context:
space:
mode:
authorBjørn Christian Seime <bjorncs@verizonmedia.com>2021-05-28 18:17:23 +0200
committerBjørn Christian Seime <bjorncs@verizonmedia.com>2021-05-28 18:17:23 +0200
commit6abceae33b9fa2724614b996fcbdef9415a17c82 (patch)
tree53c5c358f1afb6ad05ac40241412450100560698 /vespa-feed-client
parent82696c42b77f75ff0fd91c921d7d02abeb36b6db (diff)
Workaround to get rid of illegal reflection warning
Diffstat (limited to 'vespa-feed-client')
-rw-r--r--vespa-feed-client/src/main/java/ai/vespa/feed/client/HttpFeedClient.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/vespa-feed-client/src/main/java/ai/vespa/feed/client/HttpFeedClient.java b/vespa-feed-client/src/main/java/ai/vespa/feed/client/HttpFeedClient.java
index e79f8dac67e..5588694ea80 100644
--- a/vespa-feed-client/src/main/java/ai/vespa/feed/client/HttpFeedClient.java
+++ b/vespa-feed-client/src/main/java/ai/vespa/feed/client/HttpFeedClient.java
@@ -13,6 +13,7 @@ import org.apache.hc.core5.http.message.BasicHeader;
import org.apache.hc.core5.http2.config.H2Config;
import org.apache.hc.core5.net.URIBuilder;
import org.apache.hc.core5.reactor.IOReactorConfig;
+import org.apache.hc.core5.reactor.ssl.TlsDetails;
import org.apache.hc.core5.util.Timeout;
import javax.net.ssl.SSLContext;
@@ -84,7 +85,8 @@ class HttpFeedClient implements FeedClient {
.build());
ClientTlsStrategyBuilder tlsStrategyBuilder = ClientTlsStrategyBuilder.create()
- .setSslContext(constructSslContext(builder));
+ .setTlsDetailsFactory(sslEngine -> new TlsDetails(sslEngine.getSession(), sslEngine.getApplicationProtocol()))
+ .setSslContext(constructSslContext(builder));
if (builder.hostnameVerifier != null) {
tlsStrategyBuilder.setHostnameVerifier(builder.hostnameVerifier);
}