continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From eveni...@apache.org
Subject svn commit: r730078 [2/2] - in /continuum/trunk/continuum-core/src: main/java/org/apache/continuum/repository/ main/java/org/apache/continuum/taskqueue/manager/ main/java/org/apache/maven/continuum/ main/java/org/apache/maven/continuum/build/settings/ ...
Date Tue, 30 Dec 2008 09:32:55 GMT
Modified: continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/scm/queue/PrepareBuildProjectsTaskExecutor.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/scm/queue/PrepareBuildProjectsTaskExecutor.java?rev=730078&r1=730077&r2=730078&view=diff
==============================================================================
--- continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/scm/queue/PrepareBuildProjectsTaskExecutor.java
(original)
+++ continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/scm/queue/PrepareBuildProjectsTaskExecutor.java
Tue Dec 30 01:32:54 2008
@@ -41,12 +41,13 @@
 import org.apache.maven.continuum.utils.WorkingDirectoryService;
 import org.codehaus.plexus.action.ActionManager;
 import org.codehaus.plexus.action.ActionNotFoundException;
-import org.codehaus.plexus.logging.AbstractLogEnabled;
 import org.codehaus.plexus.taskqueue.Task;
 import org.codehaus.plexus.taskqueue.execution.TaskExecutionException;
 import org.codehaus.plexus.taskqueue.execution.TaskExecutor;
 import org.codehaus.plexus.util.StringUtils;
 import org.codehaus.plexus.util.dag.CycleDetectedException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * @author <a href="mailto:ctan@apache.org">Maria Catherine Tan</a>
@@ -55,9 +56,10 @@
  * role-hint="prepare-build-project"
  */
 public class PrepareBuildProjectsTaskExecutor
-    extends AbstractLogEnabled
     implements TaskExecutor
 {
+    private Logger log = LoggerFactory.getLogger( PrepareBuildProjectsTaskExecutor.class
);
+
     /**
      * @plexus.requirement
      */
@@ -104,7 +106,7 @@
             {
                 int buildDefinitionId = projectsBuildDefinitionsMap.get( projectId );
                 
-                getLogger().info( "Initializing prepare build" );
+                log.info( "Initializing prepare build" );
                 context = initializeContext( projectId, buildDefinitionId );
 
                 if ( !checkProjectScmRoot( context ) )
@@ -112,14 +114,14 @@
                     break;
                 }
 
-                getLogger().info( "Starting prepare build of project: " + AbstractContinuumAction.getProject(
context ).getName() );
+                log.info( "Starting prepare build of project: " + AbstractContinuumAction.getProject(
context ).getName() );
                 startPrepareBuild( context );
 
                 try
                 {
                     if ( AbstractContinuumAction.getBuildDefinition( context ).isBuildFresh()
)
                     {
-                        getLogger().info( "Purging existing working copy" );
+                        log.info( "Purging existing working copy" );
                         cleanWorkingDirectory( context );
                     }
 
@@ -128,10 +130,10 @@
                     // ContinuumScmResult should return a ContinuumScmResult from all
                     // methods, even in a case of failure.
                     // ----------------------------------------------------------------------
-                    getLogger().info( "Updating working dir" );
+                    log.info( "Updating working dir" );
                     updateWorkingDirectory( context );
 
-                    getLogger().info( "Merging SCM results" );
+                    log.info( "Merging SCM results" );
                     //CONTINUUM-1393
                     if ( !AbstractContinuumAction.getBuildDefinition( context ).isBuildFresh()
)
                     {
@@ -140,14 +142,14 @@
                 }
                 finally
                 {
-                    getLogger().info( "Ending prepare build of project: " + AbstractContinuumAction.getProject(
context).getName() );
+                    log.info( "Ending prepare build of project: " + AbstractContinuumAction.getProject(
context).getName() );
                     endProjectPrepareBuild( context );
                 }
             }
         }
         finally
         {
-            getLogger().info( "Ending prepare build" );
+            log.info( "Ending prepare build" );
             endPrepareBuild( context );
         }
 
@@ -361,7 +363,7 @@
 
         try
         {
-            getLogger().info( "Performing action " + actionName );
+            log.info( "Performing action " + actionName );
             actionManager.lookup( actionName ).execute( context );
             return;
         }
@@ -455,7 +457,7 @@
         
         try
         {
-            projectList = ProjectSorter.getSortedProjects( projects, getLogger() );
+            projectList = ProjectSorter.getSortedProjects( projects, log );
         }
         catch ( CycleDetectedException e )
         {
@@ -481,7 +483,7 @@
                 }
                 catch ( ContinuumStoreException e )
                 {
-                    getLogger().error( "Error while creating build object", e );
+                    log.error( "Error while creating build object", e );
                     throw new TaskExecutionException( "Error while creating build object",
e );
                 }
                 shouldBuild = true;
@@ -496,17 +498,17 @@
                     context.put( AbstractContinuumAction.KEY_BUILD_DEFINITION_ID, buildDefinitionId
);
                     context.put( AbstractContinuumAction.KEY_TRIGGER, trigger );
                     
-                    getLogger().info( "Performing action create-build-project-task" );
+                    log.info( "Performing action create-build-project-task" );
                     actionManager.lookup( "create-build-project-task" ).execute( context
);
                 }
                 catch ( ActionNotFoundException e )
                 {
-                   getLogger().error( "Error looking up action 'build-project'" );
+                   log.error( "Error looking up action 'build-project'" );
                    throw new TaskExecutionException( "Error looking up action 'build-project'",
e );
                 }
                 catch ( Exception e )
                 {
-                    getLogger().error( e.getMessage(), e );
+                    log.error( e.getMessage(), e );
                     throw new TaskExecutionException( "Error executing action 'build-project'",
e );
                 }
             }

Modified: continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java?rev=730078&r1=730077&r2=730078&view=diff
==============================================================================
--- continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java
(original)
+++ continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/utils/ProjectSorter.java
Tue Dec 30 01:32:54 2008
@@ -21,10 +21,10 @@
 
 import org.apache.maven.continuum.model.project.Project;
 import org.apache.maven.continuum.model.project.ProjectDependency;
-import org.codehaus.plexus.logging.Logger;
 import org.codehaus.plexus.util.dag.CycleDetectedException;
 import org.codehaus.plexus.util.dag.DAG;
 import org.codehaus.plexus.util.dag.TopologicalSorter;
+import org.slf4j.Logger;
 
 import java.util.ArrayList;
 import java.util.Collection;

Modified: continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/execution/ContinuumBuildExecutorTest.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/execution/ContinuumBuildExecutorTest.java?rev=730078&r1=730077&r2=730078&view=diff
==============================================================================
--- continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/execution/ContinuumBuildExecutorTest.java
(original)
+++ continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/execution/ContinuumBuildExecutorTest.java
Tue Dec 30 01:32:54 2008
@@ -79,7 +79,7 @@
         executor.setChrootJailDirectory( chrootJailFile );
         executor.setShellCommandHelper( helper );
         executor.setWorkingDirectoryService( directoryService );
-        executor.enableLogging( new ConsoleLogger( Logger.LEVEL_DEBUG, "" ) );
+        //executor.enableLogging( new ConsoleLogger( Logger.LEVEL_DEBUG, "" ) );
 
         final Project project = new Project();
         project.setId( 7 );

Modified: continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/AbstractContinuumProjectBuilderTest.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/AbstractContinuumProjectBuilderTest.java?rev=730078&r1=730077&r2=730078&view=diff
==============================================================================
--- continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/AbstractContinuumProjectBuilderTest.java
(original)
+++ continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/AbstractContinuumProjectBuilderTest.java
Tue Dec 30 01:32:54 2008
@@ -44,7 +44,7 @@
     {
         super.setUp();
         builder = new ContinuumProjectBuilder();
-        builder.enableLogging( new ConsoleLogger( Logger.LEVEL_DEBUG, "" ) );
+        //builder.enableLogging( new ConsoleLogger( Logger.LEVEL_DEBUG, "" ) );
     }
 
     /**



Mime
View raw message