Issue Details (XML | Word | Printable)

Key: MNG-3312
Type: Bug Bug
Status: Closed Closed
Resolution: Cannot Reproduce
Priority: Major Major
Assignee: Brett Porter
Reporter: Kohsuke Kawaguchi
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
Maven 2

Maven creates empty plugin metadata during offline mode, causing successive online builds to fail

Created: 06/Dec/07 01:57 AM   Updated: 12/Jun/08 08:16 PM
Component/s: Artifacts and Repositories
Affects Version/s: 2.0.7
Fix Version/s: 2.0.9

Time Tracking:
Not Specified

Issue Links:
Related
 


 Description  « Hide
Cd to any Maven project that's lying around, then do this:
rm -rf ~/.m2/repository/org/apache/maven/plugins/maven-clean-plugin
mvn -o clean

This fails, as expected, because the maven-clean-plugin doesn't exist locally. Now try this:

mvn clean

Even though now Maven is online, it still fails with the same error. No download is attempted (unless I add -U.)

This is because even in the offline mode, Maven creates ~/.m2/repository/org/apache/maven/plugins/maven-clean-plugin and put empty repository metadata. This causes the later online Maven build to believe that the repository was checked and no plugin was found there.

Maven shouldn't create an empty repository metadata in the local repository if In the offline mode.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Brett Porter added a comment - 12/Jun/08 08:16 PM
I believe this was fixed in 2.0.9