continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r763036 - in /continuum/trunk: ./ continuum-api/src/main/java/org/apache/maven/continuum/release/ continuum-release/ continuum-release/src/main/java/org/apache/continuum/release/phase/ continuum-release/src/main/java/org/apache/maven/contin...
Date Tue, 07 Apr 2009 23:36:35 GMT
Author: olamy
Date: Tue Apr  7 23:36:34 2009
New Revision: 763036

URL: http://svn.apache.org/viewvc?rev=763036&view=rev
Log:
[CONTINUUM-2160] use last maven-release-manager 2.0-beta-9


Added:
    continuum/trunk/continuum-release/src/test/resources/log4j.xml   (with props)
Modified:
    continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/release/ContinuumReleaseManager.java
    continuum/trunk/continuum-release/pom.xml
    continuum/trunk/continuum-release/src/main/java/org/apache/continuum/release/phase/AbstractContinuumRunGoalsPhase.java
    continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/executors/PrepareReleaseTaskExecutor.java
    continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/GenerateReactorProjectsPhase.java
    continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/UpdateWorkingCopyPhase.java
    continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/tasks/AbstractReleaseProjectTask.java
    continuum/trunk/continuum-webapp/pom.xml
    continuum/trunk/pom.xml

Modified: continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/release/ContinuumReleaseManager.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/release/ContinuumReleaseManager.java?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/release/ContinuumReleaseManager.java
(original)
+++ continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/release/ContinuumReleaseManager.java
Tue Apr  7 23:36:34 2009
@@ -76,7 +76,7 @@
 
     /**
      * Perform a release based on a given releaseId
-     *
+     * @deprecated to remove as not used anymore
      * @param releaseId
      * @param buildDirectory
      * @param goals
@@ -89,7 +89,7 @@
 
     /**
      * Perform a release based on a release descriptor received by the Maven Release Plugin.
-     *
+     * @deprecated to remove as not used anymore
      * @param releaseId
      * @param workingDirectory
      * @param buildDirectory
@@ -102,6 +102,22 @@
                   boolean useReleaseProfile, ContinuumReleaseManagerListener listener )
         throws ContinuumReleaseException;
 
+
+    /**
+     * FIXME use a bean to replace such very huge parameter number (ContinuumReleaseRequest)
+     * @param releaseId
+     * @param buildDirectory
+     * @param goals
+     * @param arguments
+     * @param useReleaseProfile
+     * @param listener
+     * @param repository
+     * @throws ContinuumReleaseException
+     */
+    void perform( String releaseId, File buildDirectory, String goals, String arguments,
boolean useReleaseProfile,
+                  ContinuumReleaseManagerListener listener, LocalRepository repository )
+        throws ContinuumReleaseException;    
+    
     /**
      * Rollback changes made by a previous release.
      *
@@ -119,9 +135,6 @@
 
     Map getListeners();
 
-    void perform( String releaseId, File buildDirectory, String goals, String arguments,
boolean useReleaseProfile,
-                  ContinuumReleaseManagerListener listener, LocalRepository repository )
-        throws ContinuumReleaseException;
 
     /**
      * Clean up the tagname to respect the scm provider policy.

Modified: continuum/trunk/continuum-release/pom.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-release/pom.xml?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-release/pom.xml (original)
+++ continuum/trunk/continuum-release/pom.xml Tue Apr  7 23:36:34 2009
@@ -65,7 +65,6 @@
     <dependency>
       <groupId>org.apache.maven.release</groupId>
       <artifactId>maven-release-manager</artifactId>
-      <version>1.0-alpha-3</version>
       <exclusions>
         <exclusion>
           <groupId>org.codehaus.plexus</groupId>

Modified: continuum/trunk/continuum-release/src/main/java/org/apache/continuum/release/phase/AbstractContinuumRunGoalsPhase.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-release/src/main/java/org/apache/continuum/release/phase/AbstractContinuumRunGoalsPhase.java?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-release/src/main/java/org/apache/continuum/release/phase/AbstractContinuumRunGoalsPhase.java
(original)
+++ continuum/trunk/continuum-release/src/main/java/org/apache/continuum/release/phase/AbstractContinuumRunGoalsPhase.java
Tue Apr  7 23:36:34 2009
@@ -20,14 +20,17 @@
  */
 
 import java.io.File;
+import java.util.List;
 import java.util.Map;
 
 import org.apache.continuum.release.config.ContinuumReleaseDescriptor;
 import org.apache.continuum.utils.shell.ShellCommandHelper;
 import org.apache.maven.continuum.installation.InstallationService;
 import org.apache.maven.shared.release.ReleaseExecutionException;
+import org.apache.maven.shared.release.ReleaseFailureException;
 import org.apache.maven.shared.release.ReleaseResult;
 import org.apache.maven.shared.release.config.ReleaseDescriptor;
+import org.apache.maven.shared.release.env.ReleaseEnvironment;
 import org.apache.maven.shared.release.phase.AbstractRunGoalsPhase;
 import org.codehaus.plexus.util.StringUtils;
 
@@ -68,7 +71,6 @@
 
                     executable = ( (ContinuumReleaseDescriptor) releaseDescriptor).getExecutable();
                 }
-
                 shellCommandHelper.executeGoals( determineWorkingDirectory( workingDirectory,
                                                                             releaseDescriptor.getScmRelativePathProjectDirectory()
),
                                                  executable, goals, releaseDescriptor.isInteractive(),
additionalArguments, result, 
@@ -84,4 +86,24 @@
 
         return result;
     }
+
+	@Override
+	public ReleaseResult execute(ReleaseDescriptor arg0,
+			ReleaseEnvironment arg1, File arg2, String arg3)
+			throws ReleaseExecutionException {
+		return super.execute(arg0, arg1, arg2, arg3);
+	}
+
+	public ReleaseResult execute(ReleaseDescriptor releaseDescriptor,
+			ReleaseEnvironment releaseEnvironment, List reactorProjects)
+			throws ReleaseExecutionException, ReleaseFailureException {
+		
+		return execute(releaseDescriptor, new File(releaseDescriptor.getWorkingDirectory()), releaseDescriptor.getAdditionalArguments());
+	}
+
+	public ReleaseResult simulate(ReleaseDescriptor releaseDescriptor,
+			ReleaseEnvironment releaseEnvironment, List reactorProjects)
+			throws ReleaseExecutionException, ReleaseFailureException {
+		return execute(releaseDescriptor, new File(releaseDescriptor.getWorkingDirectory()), releaseDescriptor.getAdditionalArguments());
+	}
 }

Modified: continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/executors/PrepareReleaseTaskExecutor.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/executors/PrepareReleaseTaskExecutor.java?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/executors/PrepareReleaseTaskExecutor.java
(original)
+++ continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/executors/PrepareReleaseTaskExecutor.java
Tue Apr  7 23:36:34 2009
@@ -19,14 +19,16 @@
  * under the License.
  */
 
+import java.util.ArrayList;
+
 import org.apache.maven.continuum.release.tasks.PrepareReleaseProjectTask;
 import org.apache.maven.continuum.release.tasks.ReleaseProjectTask;
 import org.apache.maven.shared.release.ReleaseResult;
 import org.apache.maven.shared.release.config.ReleaseDescriptor;
+import org.apache.maven.shared.release.env.DefaultReleaseEnvironment;
+import org.apache.maven.shared.release.env.ReleaseEnvironment;
 import org.codehaus.plexus.taskqueue.execution.TaskExecutionException;
 
-import java.util.ArrayList;
-
 /**
  * @author Edwin Punzalan
  * @version $Id$
@@ -41,8 +43,12 @@
 
         ReleaseDescriptor descriptor = prepareTask.getDescriptor();
 
-        ReleaseResult result = releaseManager.prepareWithResult( descriptor, settings, new
ArrayList(), false, false,
+       
+        ReleaseEnvironment releaseEnvironment = new DefaultReleaseEnvironment();
+        releaseEnvironment.setSettings(settings);
+        ReleaseResult result = releaseManager.prepareWithResult( descriptor, releaseEnvironment,
new ArrayList(), false, false,
                                                                  prepareTask.getListener()
);
+        
 
         //override to show the actual start time
         result.setStartTime( getStartTime() );

Modified: continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/GenerateReactorProjectsPhase.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/GenerateReactorProjectsPhase.java?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/GenerateReactorProjectsPhase.java
(original)
+++ continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/GenerateReactorProjectsPhase.java
Tue Apr  7 23:36:34 2009
@@ -38,6 +38,7 @@
 import org.apache.maven.shared.release.ReleaseFailureException;
 import org.apache.maven.shared.release.ReleaseResult;
 import org.apache.maven.shared.release.config.ReleaseDescriptor;
+import org.apache.maven.shared.release.env.ReleaseEnvironment;
 import org.apache.maven.shared.release.phase.AbstractReleasePhase;
 import org.codehaus.plexus.PlexusConstants;
 import org.codehaus.plexus.PlexusContainer;
@@ -93,6 +94,21 @@
     {
         return execute( releaseDescriptor, settings, reactorProjects );
     }
+    
+
+	public ReleaseResult execute(ReleaseDescriptor releaseDescriptor,
+			ReleaseEnvironment releaseEnvironment, List reactorProjects)
+			throws ReleaseExecutionException, ReleaseFailureException {
+		return execute(releaseDescriptor, releaseEnvironment.getSettings(),
+				reactorProjects);
+	}
+
+	public ReleaseResult simulate(ReleaseDescriptor releaseDescriptor,
+			ReleaseEnvironment releaseEnvironment, List reactorProjects)
+			throws ReleaseExecutionException, ReleaseFailureException {
+		return execute(releaseDescriptor, releaseEnvironment.getSettings(),
+				reactorProjects);
+	}    
 
     private List getReactorProjects( ReleaseDescriptor descriptor )
         throws ContinuumReleaseException
@@ -241,9 +257,10 @@
         }
     }
 
-    public void contextualize( Context context )
-        throws ContextException
-    {
-        container = (PlexusContainer) context.get( PlexusConstants.PLEXUS_KEY );
-    }
+
+	public void contextualize(Context context) throws ContextException {
+		container = (PlexusContainer) context.get(PlexusConstants.PLEXUS_KEY);
+	}
+
+
 }

Modified: continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/UpdateWorkingCopyPhase.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/UpdateWorkingCopyPhase.java?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/UpdateWorkingCopyPhase.java
(original)
+++ continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/phase/UpdateWorkingCopyPhase.java
Tue Apr  7 23:36:34 2009
@@ -32,6 +32,7 @@
 import org.apache.maven.shared.release.ReleaseFailureException;
 import org.apache.maven.shared.release.ReleaseResult;
 import org.apache.maven.shared.release.config.ReleaseDescriptor;
+import org.apache.maven.shared.release.env.ReleaseEnvironment;
 import org.apache.maven.shared.release.phase.AbstractReleasePhase;
 import org.apache.maven.shared.release.scm.ReleaseScmCommandException;
 import org.apache.maven.shared.release.scm.ReleaseScmRepositoryException;
@@ -120,4 +121,18 @@
     {
         this.copyUpdated = copyUpdated;
     }
+
+	public ReleaseResult execute(ReleaseDescriptor releaseDescriptor,
+			ReleaseEnvironment releaseEnvironment, List reactorProjects)
+			throws ReleaseExecutionException, ReleaseFailureException {
+		return execute(releaseDescriptor, releaseEnvironment.getSettings(),
+				reactorProjects);
+	}
+
+	public ReleaseResult simulate(ReleaseDescriptor releaseDescriptor,
+			ReleaseEnvironment releaseEnvironment, List reactorProjects)
+			throws ReleaseExecutionException, ReleaseFailureException {
+		return execute(releaseDescriptor, releaseEnvironment.getSettings(),
+				reactorProjects);
+	}
 }

Modified: continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/tasks/AbstractReleaseProjectTask.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/tasks/AbstractReleaseProjectTask.java?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/tasks/AbstractReleaseProjectTask.java
(original)
+++ continuum/trunk/continuum-release/src/main/java/org/apache/maven/continuum/release/tasks/AbstractReleaseProjectTask.java
Tue Apr  7 23:36:34 2009
@@ -19,7 +19,6 @@
  * under the License.
  */
 
-import org.apache.maven.continuum.model.system.Profile;
 import org.apache.maven.shared.release.ReleaseManagerListener;
 import org.apache.maven.shared.release.config.ReleaseDescriptor;
 import org.codehaus.plexus.taskqueue.Task;

Added: continuum/trunk/continuum-release/src/test/resources/log4j.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-release/src/test/resources/log4j.xml?rev=763036&view=auto
==============================================================================
--- continuum/trunk/continuum-release/src/test/resources/log4j.xml (added)
+++ continuum/trunk/continuum-release/src/test/resources/log4j.xml Tue Apr  7 23:36:34 2009
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+  -->
+
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
+
+  <appender name="default" class="org.apache.log4j.ConsoleAppender">
+    <param name="Target" value="System.out"/>
+    <param name="Threshold" value="DEBUG"/>
+
+    <layout class="org.apache.log4j.PatternLayout">
+      <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p %-20c [%C] %m%n"/>
+    </layout>
+  </appender>
+
+  <!-- quiet spring loading :-) -->
+  <category name="org.springframework">
+    <priority value="ERROR"/>
+  </category>
+  <category name="org.codehaus.plexus">
+    <priority value="ERROR"/>
+  </category>
+
+  <category name="JPOX">
+    <priority value="ERROR"/>
+    <appender-ref ref="default"/>
+  </category>
+
+  <root>
+    <priority value="INFO"/>
+    <appender-ref ref="default"/>
+  </root>
+
+</log4j:configuration>

Propchange: continuum/trunk/continuum-release/src/test/resources/log4j.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/trunk/continuum-release/src/test/resources/log4j.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: continuum/trunk/continuum-webapp/pom.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-webapp/pom.xml?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/continuum-webapp/pom.xml (original)
+++ continuum/trunk/continuum-webapp/pom.xml Tue Apr  7 23:36:34 2009
@@ -464,6 +464,16 @@
       <scope>runtime</scope>
     </dependency>
     <dependency>
+      <groupId>org.apache.maven.release</groupId>
+      <artifactId>maven-release-manager</artifactId>
+      <exclusions>
+        <exclusion>
+          <groupId>org.codehaus.plexus</groupId>
+          <artifactId>plexus-container-default</artifactId>
+        </exclusion>
+      </exclusions>
+    </dependency>    
+    <dependency>
       <groupId>org.apache.continuum</groupId>
       <artifactId>continuum-notifier-irc</artifactId>
       <scope>runtime</scope>

Modified: continuum/trunk/pom.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/pom.xml?rev=763036&r1=763035&r2=763036&view=diff
==============================================================================
--- continuum/trunk/pom.xml (original)
+++ continuum/trunk/pom.xml Tue Apr  7 23:36:34 2009
@@ -413,7 +413,18 @@
         <groupId>org.apache.maven.scm</groupId>
         <artifactId>maven-scm-provider-svn-commons</artifactId>
         <version>${maven-scm.version}</version>
-      </dependency>         
+      </dependency>    
+	  <dependency>
+	    <groupId>org.apache.maven.release</groupId>
+	    <artifactId>maven-release-manager</artifactId>
+	    <version>2.0-beta-9</version>
+	    <exclusions>
+          <exclusion>
+            <groupId>org.codehaus.plexus</groupId>
+            <artifactId>plexus-container-default</artifactId>
+          </exclusion>
+	    </exclusions>
+	  </dependency>           
       <dependency>
         <groupId>org.apache.maven.wagon</groupId>
         <artifactId>wagon-provider-api</artifactId>



Mime
View raw message