Can't get the correct package from Nexus? error in "mvn help: effective-settings"
I am using open source version of maven 2.2.1
When I type "mvn help: effective-settings" I got below error
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'help'.
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error building POM (may not be this project POM).
Project ID: org.apache.maven.plugins:maven-help-plugin
Reason: Error getting POM for 'org.apache.maven.plugins:maven-help-plugin' from the repository: Failed to resolve artifact, possibly due to a repository list that is not appropriately equipped for this artifact metadata.
org.apache.maven.plugins:maven-help-plugin:pom:2.2-SNAPSHOT
from the specified remote repositories:
Nexus (http://192.168.56.191:8081/nexus/content/groups/public)
for project org.apache.maven.plugins:maven-help-plugin
When I check out the local repository at ~ .m2 \ repository \ org \ apache \ maven \ plugins \ maven-help-plugin
It has a maven-metadata-central.xml file
<?xml version="1.0" encoding="UTF-8"?>
<metadata>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-help-plugin</artifactId>
<versioning>
<latest>2.2-SNAPSHOT</latest>
<release>2.1.1</release>
<versions>
<version>2.0</version>
<version>2.0.1</version>
<version>2.0.2</version>
<version>2.1</version>
<version>2.1.1</version>
<version>2.2-SNAPSHOT</version>
</versions>
<lastUpdated>20100519065440</lastUpdated>
</versioning>
</metadata>
And I can't find the jar files under the directory, what happened to the nexus server? I cannot easily find support information from nexus.
Any hints
a source to share
That's definitely like Brian said. You probably only have mirrored repos without doing a profile customization hack as the connection documentation speaks to these bogus center urls. If you run maven in debug mode, you will see things like "Skipping a disabled central repository". - disabled refers to the policy applied to a specific artifact.
Since you want a SNAPSHOT artifact that probably has the appropriate policy <snapshots> <enabled>true</enabled>
and maven central does <snapshots> <enabled>false</enabled>
, it doesn't work without cracking the documentation documentation.
The mirror only replaces the url, it does not change the policies of the source repositories, but the repo manager usually needs to redirect both release and snapshot artifacts to work
Hope it helps clarify this issue, good to know about it
a source to share
It looks like you might have wrong settings.xml settings. Try installing this one and if you still have problems ask us on nexus-user and we'll go from there.
a source to share