continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@apache.org
Subject svn commit: r822134 - /continuum/branches/continuum-1.3.x/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
Date Tue, 06 Oct 2009 05:52:47 GMT
Author: ctan
Date: Tue Oct  6 05:52:47 2009
New Revision: 822134

URL: http://svn.apache.org/viewvc?rev=822134&view=rev
Log:
[CONTINUUM-1031] use getBuildResultsForProject instead of getProjectWithBuilds to improve
performance when deleting a project

Modified:
    continuum/branches/continuum-1.3.x/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java

Modified: continuum/branches/continuum-1.3.x/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-1.3.x/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java?rev=822134&r1=822133&r2=822134&view=diff
==============================================================================
--- continuum/branches/continuum-1.3.x/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
(original)
+++ continuum/branches/continuum-1.3.x/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
Tue Oct  6 05:52:47 2009
@@ -591,7 +591,7 @@
     {
         try
         {
-            Project project = getProjectWithBuilds( projectId );
+            Project project = getProject( projectId );
 
             try
             {
@@ -660,9 +660,10 @@
 
             log.info( "Remove project " + project.getName() + "(" + projectId + ")" );
 
-            for ( Object o : project.getBuildResults() )
+            Collection<BuildResult> buildResults = getBuildResultsForProject( projectId
);
+
+            for ( BuildResult br : buildResults )
             {
-                BuildResult br = (BuildResult) o;
                 br.setBuildDefinition( null );
                 //Remove all modified dependencies to prevent SQL errors
                 br.setModifiedDependencies( null );



Mime
View raw message