continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@apache.org
Subject svn commit: r725673 - in /continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder: distributed/executor/DistributedBuildProjectTaskExecutor.java utils/ContinuumBuildConstant.java
Date Thu, 11 Dec 2008 12:24:55 GMT
Author: ctan
Date: Thu Dec 11 04:24:54 2008
New Revision: 725673

URL: http://svn.apache.org/viewvc?rev=725673&view=rev
Log:
add projectGroupId and scmRootAddress to buildContext

Modified:
    continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
    continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/utils/ContinuumBuildConstant.java

Modified: continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java?rev=725673&r1=725672&r2=725673&view=diff
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
(original)
+++ continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/distributed/executor/DistributedBuildProjectTaskExecutor.java
Thu Dec 11 04:24:54 2008
@@ -125,7 +125,8 @@
             }
 
             int ctr = 0;
-            
+            String scmRootAddress = "";
+
             for ( Project project : projects )
             {
                 if ( ctr == 0 )
@@ -135,6 +136,7 @@
                     {
                         if ( project.getScmUrl().startsWith( scmRoot.getScmRootAddress()
) )
                         {
+                            scmRootAddress = scmRoot.getScmRootAddress();
                             scmRoot.setOldState( scmRoot.getState() );
                             scmRoot.setState( ContinuumProjectState.UPDATING );
                             projectScmRootDao.updateProjectScmRoot( scmRoot );
@@ -149,6 +151,8 @@
                     buildResultDao.getLatestBuildResultForBuildDefinition( project.getId(),
buildDefinitionId );
 
                 Map context = new HashMap();
+                context.put( ContinuumBuildConstant.KEY_PROJECT_GROUP_ID, project.getProjectGroup().getId()
);
+                context.put( ContinuumBuildConstant.KEY_SCM_ROOT_ADDRESS, scmRootAddress
);
                 context.put( ContinuumBuildConstant.KEY_PROJECT_ID, project.getId() );
                 context.put( ContinuumBuildConstant.KEY_EXECUTOR_ID, project.getExecutorId()
);
                 context.put( ContinuumBuildConstant.KEY_SCM_URL, project.getScmUrl() );

Modified: continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/utils/ContinuumBuildConstant.java
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/utils/ContinuumBuildConstant.java?rev=725673&r1=725672&r2=725673&view=diff
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/utils/ContinuumBuildConstant.java
(original)
+++ continuum/branches/continuum-distributed-builds/continuum-builder/src/main/java/org/apache/continuum/builder/utils/ContinuumBuildConstant.java
Thu Dec 11 04:24:54 2008
@@ -46,6 +46,10 @@
 
     public static final String KEY_PREPARE_BUILD_FINISHED = "prepare-build-finished";
 
+    public static final String KEY_PROJECT_GROUP_ID = "project-group-id";
+
+    public static final String KEY_SCM_ROOT_ADDRESS = "scm-root-address";
+
     public static int getProjectId( Map context )
     {
         return getInteger( context, KEY_PROJECT_ID );



Mime
View raw message