clientBuilder.sslSocketFactory(SSLSocketFactory) not supported on JDK 9+ while running maven build

Total
4
Shares

I have imported an existing maven project into eclipse. When I try to build the maven project I get error ‘clientBuilder.sslSocketFactory(SSLSocketFactory) not supported on JDK 9+’ message. I have JDK 8 and Maven version ‘Apache Maven 3.0.5’ installed. Eclipse Version is Photon Milestone 3 (4.8.0M3).
My POM file looks like below.

Can someone please help me resolve this?

_x000D_

_x000D_

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>NBE_Proxibid</groupId>
    <artifactId>NBE_Proxibid</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <packaging>jar</packaging>
    <name>NBE_Proxibid</name>
    <url>http://maven.apache.org</url>
    <build>
        <sourceDirectory>src</sourceDirectory>
        <resources>
            <resource>
                <directory>src</directory>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.7.0</version>
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>2.19.1</version>
            </plugin>
        </plugins>
    </build>
    <dependencies>
        <dependency>
            <groupId>io.appium</groupId>
            <artifactId>java-client</artifactId>
            <version>5.0.4</version>
        </dependency>

<!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-java -->
<dependency>
    <groupId>org.seleniumhq.selenium</groupId>
    <artifactId>selenium-java</artifactId>
    <version>3.13.0</version>
</dependency>

        <!-- JFreeChart is a class library, currently supporting bar charts, pie 
            charts, line charts, XY-plots and time series plots. -->
        <dependency>
            <groupId>org.jfree</groupId>
            <artifactId>jfreechart</artifactId>
            <version>1.5.0</version>
        </dependency>
        <dependency>
            <groupId>org.testng</groupId>
            <artifactId>testng</artifactId>
            <version>6.13.1</version>
            <!-- <scope>test</scope> -->
        </dependency>
        <dependency>
            <groupId>org.apache.poi</groupId>
            <artifactId>poi</artifactId>
            <version>3.17</version>
        </dependency>
    <!--    <dependency>
            <groupId>com.relevantcodes</groupId>
            <artifactId>extentreports</artifactId>
            <version>2.41.2</version>
        </dependency> -->
        <dependency>
             <groupId>com.aventstack</groupId>
             <artifactId>extentreports</artifactId>
             <version>3.1.5</version>
        </dependency> 
        <dependency>
            <groupId>javax.mail</groupId>
            <artifactId>mail</artifactId>
            <version>1.4.7</version>
        </dependency>
        <dependency>
            <groupId>com.itextpdf.tool</groupId>
            <artifactId>xmlworker</artifactId>
            <version>5.4.1</version>
        </dependency>
        <dependency>
            <groupId>io.rest-assured</groupId>
            <artifactId>rest-assured</artifactId>
            <version>3.0.6</version>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.json/json -->
        <dependency>
            <groupId>org.json</groupId>
             <artifactId>json</artifactId>
             <version>20171018</version>
        </dependency>
            <!-- https://mvnrepository.com/artifact/com.googlecode.json-simple/json-simple -->
        <dependency>
             <groupId>com.googlecode.json-simple</groupId>
             <artifactId>json-simple</artifactId>
             <version>1.1.1</version>
        </dependency>
    <!-- https://mvnrepository.com/artifact/ru.yandex.qatools.ashot/ashot -->
    <dependency>
        <groupId>ru.yandex.qatools.ashot</groupId>
        <artifactId>ashot</artifactId>
        <version>1.5.4</version>
    </dependency>
    <!-- https://mvnrepository.com/artifact/com.microsoft.sqlserver/sqljdbc4 -->
    <dependency>
        <groupId>com.microsoft.sqlserver</groupId>
        <artifactId>sqljdbc4</artifactId>
        <version>4.0</version>      
    </dependency>
    <dependency>
        <groupId>com.opencsv</groupId>
        <artifactId>opencsv</artifactId>
        <version>4.1</version>
</dependency>
    </dependencies>
</project>

_x000D_

_x000D_

_x000D_

This is the error that I get:

_x000D_

_x000D_

    [INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.490 s
[INFO] Finished at: 2021-05-19T18:12:53+05:30
[INFO] Final Memory: 12M/243M
[INFO] ------------------------------------------------------------------------
[ERROR] clientBuilder.sslSocketFactory(SSLSocketFactory) not supported on JDK 9+
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.

_x000D_

_x000D_

_x000D_


Solution

This issue was resolved after I installed Eclipse Oxygen. Turns out it was plugin issue in the eclipse build that I had.

Leave a Reply

Your email address will not be published. Required fields are marked *