continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@apache.org
Subject svn commit: r812745 - /continuum/branches/continuum-1.3.x/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
Date Wed, 09 Sep 2009 01:37:39 GMT
Author: ctan
Date: Wed Sep  9 01:37:39 2009
New Revision: 812745

URL: http://svn.apache.org/viewvc?rev=812745&view=rev
Log:
[CONTINUUM-2356] fixed build order in distributed build

Modified:
    continuum/branches/continuum-1.3.x/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java

Modified: continuum/branches/continuum-1.3.x/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-1.3.x/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java?rev=812745&r1=812744&r2=812745&view=diff
==============================================================================
--- continuum/branches/continuum-1.3.x/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
(original)
+++ continuum/branches/continuum-1.3.x/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
Wed Sep  9 01:37:39 2009
@@ -131,19 +131,15 @@
         throws ContinuumException
     {
         List<Map<String, Object>> buildContext = new ArrayList<Map<String,
Object>>();
-        List<Project> projects = new ArrayList<Project>();
 
         try
         {
-            for ( Integer projectId : projectsAndBuildDefinitions.keySet() )
-            {
-                Project project = projectDao.getProjectWithDependencies( projectId );
-                projects.add( project );
-            }
+            ProjectScmRoot scmRoot = projectScmRootDao.getProjectScmRoot( scmRootId );
 
-            projects = ProjectSorter.getSortedProjects( projects, null );
+            List<Project> projects = projectDao.getProjectsWithDependenciesByGroupId(
scmRoot.getProjectGroup().getId() );
+            List<Project> sortedProjects = ProjectSorter.getSortedProjects( projects,
null );
 
-            for ( Project project : projects )
+            for ( Project project : sortedProjects )
             {
                 int buildDefinitionId = projectsAndBuildDefinitions.get( project.getId()
);
                 BuildDefinition buildDef = buildDefinitionDao.getBuildDefinition( buildDefinitionId
);



Mime
View raw message