]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-8012 Restore support of IBM JVM in WS client 1176/head
authorJulien HENRY <julien.henry@sonarsource.com>
Thu, 25 Aug 2016 14:10:33 +0000 (16:10 +0200)
committerJulien HENRY <julien.henry@sonarsource.com>
Fri, 26 Aug 2016 08:19:39 +0000 (10:19 +0200)
sonar-ws/src/main/java/org/sonarqube/ws/client/HttpConnector.java

index d063fe9383b2d8512a8621c8e75884a17c0e88e5..0ffe844c408c8b2f712ba804ccee556e5857eb9c 100644 (file)
@@ -25,7 +25,6 @@ import java.util.Map;
 import java.util.concurrent.TimeUnit;
 import javax.annotation.CheckForNull;
 import javax.annotation.Nullable;
-import javax.net.ssl.SSLSocketFactory;
 import okhttp3.Call;
 import okhttp3.ConnectionSpec;
 import okhttp3.Credentials;
@@ -101,19 +100,10 @@ public class HttpConnector implements WsConnector {
       .supportsTlsExtensions(true)
       .build();
     okHttpClientBuilder.connectionSpecs(asList(tls, ConnectionSpec.CLEARTEXT));
-    okHttpClientBuilder.sslSocketFactory(createSslSocketFactory());
 
     return okHttpClientBuilder.build();
   }
 
-  private static SSLSocketFactory createSslSocketFactory() {
-    try {
-      return (SSLSocketFactory) SSLSocketFactory.getDefault();
-    } catch (Exception e) {
-      throw new IllegalStateException("Fail to init TLS context", e);
-    }
-  }
-
   @Override
   public String baseUrl() {
     return baseUrl.url().toExternalForm();