maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sisb...@apache.org
Subject svn commit: r721110 - /maven/components/trunk/maven-project/src/main/java/org/apache/maven/project/artifact/MavenMetadataSource.java
Date Thu, 27 Nov 2008 07:36:07 GMT
Author: sisbell
Date: Wed Nov 26 23:36:06 2008
New Revision: 721110

URL: http://svn.apache.org/viewvc?rev=721110&view=rev
Log:
Don't fail build on invalid relocated pom.

Modified:
    maven/components/trunk/maven-project/src/main/java/org/apache/maven/project/artifact/MavenMetadataSource.java

Modified: maven/components/trunk/maven-project/src/main/java/org/apache/maven/project/artifact/MavenMetadataSource.java
URL: http://svn.apache.org/viewvc/maven/components/trunk/maven-project/src/main/java/org/apache/maven/project/artifact/MavenMetadataSource.java?rev=721110&r1=721109&r2=721110&view=diff
==============================================================================
--- maven/components/trunk/maven-project/src/main/java/org/apache/maven/project/artifact/MavenMetadataSource.java
(original)
+++ maven/components/trunk/maven-project/src/main/java/org/apache/maven/project/artifact/MavenMetadataSource.java
Wed Nov 26 23:36:06 2008
@@ -364,9 +364,19 @@
     private void handleInvalidOrMissingMavenPOM( Artifact artifact, ProjectBuildingException
e )
         throws ArtifactMetadataRetrievalException
     {
+        if ( strictlyEnforceThePresenceOfAValidMavenPOM )
+        {
             throw new ArtifactMetadataRetrievalException(
                 "Invalid POM file for artifact: '" + artifact.getDependencyConflictId() +
"': " + e.getMessage(), e,
                 artifact );
+        }
+        else
+        {
+            getLogger().warn( "\n\tDEPRECATION: The POM for the artifact '" + artifact.getDependencyConflictId()
+
+                "' was invalid or not found on any repositories.\n" +
+                "\tThis may not be supported by future versions of Maven and should be corrected
as soon as possible.\n" +
+                "\tError given: " + e.getMessage() + "\n" );
+        }
     }
 
     private void loadProjectBuilder()



Mime
View raw message