Defining a mirror invalidates local repository content ------------------------------------------------------
Key: MNG-5029 URL: http://jira.codehaus.org/browse/MNG-5029 Project: Maven 2 & 3 Issue Type: Bug Components: Artifacts and Repositories Affects Versions: 3.0.2 Environment: ubuntu, maven 3.0.2 Reporter: Henrik Lynggaard Priority: Critical If I define a mirror in settings.xml, maven can no longer find artifacts which are allready in the local repository. Steps to reproduce. 1. Create simple pom like <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>dk.hlyh.par</groupId> <artifactId>par</artifactId> <version>1.0</version> <packaging>pom</packaging> <name>par</name> </project> 2. make sure setting.xml has no mirrors 3. build using mvn -o install (which completes succssfully, hence all artifacts available locally) 4. add mirror to settings.xml (mirror must be of * or central) 5. rebuild using mvn -o install expected result: * the build completes without error actual result: Build fails with: [ERROR] Plugin org.apache.maven.plugins:maven-install-plugin:2.3.1 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-install-plugin:jar:2.3.1: The repository system is offline but the artifact org.apache.maven.plugins:maven-install-plugin:pom:2.3.1 is not available in the local repository. but given step 3 above I know all required artifacts are available locally, hence the build should not fail. -- 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