I'm trying to add eclipse pmd plug-in ended up with the following error.
Unable to read repository at https://sourceforge.net/projects/pmd/files/pmd-eclipse/update-site/content.xml.
Received fatal alert: handshake_failure
Any idea what's wrong ?
I'm trying to add eclipse pmd plug-in ended up with the following error.
Unable to read repository at https://sourceforge.net/projects/pmd/files/pmd-eclipse/update-site/content.xml.
Received fatal alert: handshake_failure
Any idea what's wrong ?
It's probably one of the following two cases:
Either the cipher is not supported by your JRE - see answer https://stackoverflow.com/a/42129608/1169968 to install the JCE security patch to allow unlimited security (local_policy.jar and US_export_policy.jar)
The JRE version, you are using, doesn't trust Let's Encrypt certificates, that are used by some of the sourceforge mirrors. You need at least Java 7 Update 111 or Java 8 Update 101. See https://letsencrypt.org/docs/certificate-compatibility/
But even then, the eclipse update site hosted on sourceforge seems to be very unreliable - the mirrors are not always 100% in sync, so some files might be missing...
Therefore, see https://github.com/pmd/pmd-eclipse-plugin/issues/19 for an workaround:
download the update site as a zip archive from https://github.com/pmd/pmd-eclipse-plugin/releases , unpack it locally and use this folder as an update site.
A new update-site is available now:
https://dl.bintray.com/pmd/pmd-eclipse-plugin/updates/
Please use this url from now on, to install the plugin.
This is because of java security. Replace jars(two jars namely local_policy.jar and US_export_policy.jar) in %JRE%/lib/security with jars in http://www.oracle.com/technetwork/java/javase/downloads/jce-7-download-432124.html
Note: Here %JRE% means the jre location which eclipse is using. Find it at Windows -> Preference -> Java -> Installed JREs
Firstly, unless you are using an old update of Java (regardless of Java version), issues relating Java Cryptography Extension (JCE) are now completely irrelevant. See cranphin's answer on this SO post: How to avoid installing "Unlimited Strength" JCE policy files when deploying an application?
Secondly, DO NOT USE sourceforge to download the plugin. Like the OP and many others, I also got that handshake_failure.
The approach that worked for me was to go to Eclipse Marketplace (https://marketplace.eclipse.org/content/eclipse-pmd) and drag the Install button on that page into the Eclipse workspace.
After doing that you should see the following screen in Eclipse:
Click Confirm, accept the license agreement and then click Install anyway when the unsigned content dialog is shown. If all goes well the plugin will be installed and you will be invited to restart Eclipse.
Once Eclipse has restarted, verify that the plugin is installed: Help->About->Installation Details->Installed Software:
That's it. (My environment was Windows 10 + Eclipse Oxygen.2 Release (4.7.2) + JDK9.)