openstack4j
openstack4j copied to clipboard
JDK11: Okhttp Exception
Hello, We are using version 3.2.0. When we moved to JDK 11 platform, we are seeing the following exception:
2020-07-25 05:44:35,273 ERROR [ajp-nio-0.0.0.0-8009-exec-8] UnsupportedDeviceVersionExceptionMapper - clientBuilder.sslSocketFactory(SSLSocketFactory) not supported on JDK 9+ java.lang.UnsupportedOperationException: clientBuilder.sslSocketFactory(SSLSocketFactory) not supported on JDK 9+ at okhttp3.internal.platform.Jdk9Platform.trustManager(Jdk9Platform.kt:61) ~[okhttp-4.8.0.jar:?] at okhttp3.OkHttpClient$Builder.sslSocketFactory(OkHttpClient.kt:751) ~[okhttp-4.8.0.jar:?] at org.openstack4j.connectors.okhttp.HttpCommand.initialize(HttpCommand.java:87) ~[openstack4j-okhttp-3.2.0.jar:?] at org.openstack4j.connectors.okhttp.HttpCommand.create(HttpCommand.java:61) ~[openstack4j-okhttp-3.2.0.jar:?] at org.openstack4j.connectors.okhttp.HttpExecutorServiceImpl.invoke(HttpExecutorServiceImpl.java:50) ~[openstack4j-okhttp-3.2.0.jar:?] at org.openstack4j.connectors.okhttp.HttpExecutorServiceImpl.execute(HttpExecutorServiceImpl.java:30) ~[openstack4j-okhttp-3.2.0.jar:?] at org.openstack4j.core.transport.internal.HttpExecutor.execute(HttpExecutor.java:51) ~[openstack4j-core-3.2.0.jar:?] at org.openstack4j.openstack.internal.OSAuthenticator.authenticateV3(OSAuthenticator.java:187) ~[openstack4j-core-3.2.0.jar:?] at org.openstack4j.openstack.internal.OSAuthenticator.invoke(OSAuthenticator.java:74) ~[openstack4j-core-3.2.0.jar:?] at org.openstack4j.openstack.client.OSClientBuilder$ClientV3.authenticate(OSClientBuilder.java:172) ~[openstack4j-core-3.2.0.jar:?] at org.openstack4j.openstack.client.OSClientBuilder$ClientV3.authenticate(OSClientBuilder.java:129) ~[openstack4j-core-3.2.0.jar:?]
How can we overcome this? I found that few other libraries using okhttp APIs have made the fix to use the OKHTTP api by passing their custom TrustManager. Can we get this fixed for opnestack4j as well?
Thanks !!