Solution 1: configure Java 7
It is need to enable TLS 1.2 protocol with Java property in the command line
mvn -Dhttps.protocols=TLSv1.2 install
install
is just an example of a goal
The same error for ant
can be solved by this way
java -Dhttps.protocols=TLSv1.2 -cp %ANT_HOME%/lib/ant-launcher.jar org.apache.tools.ant.launch.Launcher
Solution 2: use Java 7 with Oracle Advanced Support
Also problem can be solved by updating the Java 7 version. But the last available version (7u80
) doesn't fix the problem. It is need to use an update provided with Oracle Advanced Support (formerly known as Java for Business).
Solution 3: use Java 8 instead
Configure $JAVA_HOME
to point to Java 8.