Unable to resolve Dashboard mojo from Central ---------------------------------------------
Key: MNG-4001 URL: http://jira.codehaus.org/browse/MNG-4001 Project: Maven 2 Issue Type: Bug Components: Sites & Reporting Affects Versions: 2.0.9 Environment: Windows, JDK 1.6 Reporter: Anthony Whitford Attachments: dashbug.zip I have a simple test project that declares the dashboard-maven-plugin (see http://mojo.codehaus.org/dashboard-maven-plugin/usage.html ). Note that the usage does explicitly state that the Codehaus repository must be specified as a plugin repository... However, according to: http://maven.apache.org/guides/introduction/introduction-to-plugin-prefix-mapping.html I'm pretty sure that Maven should be able to resolve the dashboard-maven-plugin from the central repo. I validated that the [dashboard-maven-plugin residing in central|http://repo1.maven.org/maven2/org/codehaus/mojo/dashboard-maven-plugin/1.0.0-beta-1/] is indeed the same artifact as that which lives at the [codehaus repository|http://repository.codehaus.org/org/codehaus/mojo/dashboard-maven-plugin/1.0.0-beta-1/]. But as you can see from my attached test case, the codehaus mojo is NOT being resolved without the special plugin repository defined. When running {noformat}mvn dashboard:dashboard{noformat}, I get the following error message: {noformat} [INFO] Scanning for projects... [INFO] Searching repository for plugin with prefix: 'dashboard'. [INFO] ------------------------------------------------------------------------ [ERROR] BUILD ERROR [INFO] ------------------------------------------------------------------------ [INFO] The plugin 'org.apache.maven.plugins:maven-dashboard-plugin' does not exist or no valid version could be found [INFO] ------------------------------------------------------------------------ [INFO] For more information, run Maven with the -e switch [INFO] ------------------------------------------------------------------------ [INFO] Total time: < 1 second [INFO] Finished at: Sat Jan 24 12:40:55 PST 2009 [INFO] Final Memory: 1M/254M [INFO] ------------------------------------------------------------------------{noformat} If you edit the pom.xml to uncomment out the plugin repository declaration for codehaus, it works as one would expect. My understanding is that the only reason why the Dashboard Usage mentions their plugin repository is because the artifact was not available on the central repository -- but it certainly is today. I also thought that perhaps the maven-metadata.xml might be incorrect (perhaps the dashboard plugin prefix is missing or different). I checked: * http://repo1.maven.org/maven2/org/codehaus/mojo/maven-metadata.xml * http://repository.codehaus.org/org/codehaus/mojo/maven-metadata.xml and they both look OK to me... I clearly see:{code:xml} <plugin> <name>Maven Dashboard Report Plugin</name> <prefix>dashboard</prefix> <artifactId>dashboard-maven-plugin</artifactId> </plugin> {code} And I don't see any plugin with a dashboard prefix specified as an Apache Maven Plugin here: * http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-metadata.xml If I explicitly specify the dashboard plugin like: {noformat}mvn org.codehaus.mojo:dashboard-maven-plugin:dashboard{noformat} that works... Overall, I am recording a bug because the [documentation|http://maven.apache.org/guides/introduction/introduction-to-plugin-prefix-mapping.html] states:{quote} Maven will always search the following groupId's after searching any plugin groups specified in the user's settings: * org.apache.maven.plugins * org.codehaus.mojo {quote} I don't see this being done. Finally, I even tried adding a {{pluginGroups}} to my {{settings.xml}}:{code:xml} <pluginGroups> <pluginGroup>org.codehaus.mojo</pluginGroup> </pluginGroups> {code} But that did not work either... -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira