]> source.dussan.org Git - archiva.git/commitdiff
-merge changes from archiva-1.0.x branch -r630722
authorMaria Odea B. Ching <oching@apache.org>
Mon, 25 Feb 2008 07:38:31 +0000 (07:38 +0000)
committerMaria Odea B. Ching <oching@apache.org>
Mon, 25 Feb 2008 07:38:31 +0000 (07:38 +0000)
git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@630750 13f79535-47bb-0310-9956-ffa450edef68

archiva-base/archiva-repository-layer/src/main/java/org/apache/maven/archiva/repository/project/filters/EffectiveProjectModelFilter.java

index 76225b8fdf7e1dd6ddb2ad1fcfd37022263f6bb7..24a22f90c00667bf20a5fa1ace38677eb1cc560f 100644 (file)
@@ -111,10 +111,15 @@ public class EffectiveProjectModelFilter
         // Resolve dependency versions from dependency management.
         applyDependencyManagement( effectiveProject );
 
-        synchronized ( effectiveProjectCache )
+        // Do not add project into cache if it contains no groupId and
+        // version information
+        if ( project.getGroupId() != null && project.getVersion() != null )
         {
-            DEBUG( "Putting (to cache/projectKey): " + projectKey );
-            effectiveProjectCache.put( projectKey, effectiveProject );
+            synchronized ( effectiveProjectCache )
+            {
+                DEBUG( "Putting (to cache/projectKey): " + projectKey );
+                effectiveProjectCache.put( projectKey, effectiveProject );
+            }
         }
 
         // Return what we got.