Issue
I am using NetBeans IDE 8.2 with Maven 3.5.0. When one of the actions from NetBeans tries to download a plugin, it fails:
Downloading: https://repo.maven.apache.org/maven2/org/codehaus/mojo/xml-maven-plugin/1.0/xml-maven-plugin-1.0.pom
Failed to retrieve plugin descriptor for org.codehaus.mojo:xml-maven-plugin:1.0: Plugin org.codehaus.mojo:xml-maven-plugin:1.0 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.codehaus.mojo:xml-maven-plugin:jar:1.0
I defined the proxy at:
- NetBeans: Tools -> Options -> General
- C:\Program Files\apache-maven-3.5.0\conf\settings.xml
- C:\Users[MyUser].m2
In both settings files, I tried to add proxy for both http and https, with and without optional id, and also tried to change the order.
<proxy>
<id>optional</id>
<active>true</active>
<protocol>https</protocol>
<host>RealProxyIP</host>
<port>RealProxyPort</port>
</proxy>
Every time, it looks like working from the command line works properly (I also used mvn help:effective-settings to verify the settings changes), but from NetBeans the download still fails (and it takes about 30 minutes for NetBeans to stop trying to download the plugins).
Any advice?
Thanks
Solution
The problem was caused because of one of the values in the "No Proxy Hosts" (in Advanced proxy settings). I deleted the values there, and everything worked.
Answered By - Sivan R
Answer Checked By - Marilyn (JavaFixing Volunteer)