continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From eveni...@apache.org
Subject svn commit: r430175 - in /maven/continuum/trunk/continuum-webapp/src/main: java/org/apache/maven/continuum/web/action/ resources/
Date Wed, 09 Aug 2006 22:51:39 GMT
Author: evenisse
Date: Wed Aug  9 15:51:38 2006
New Revision: 430175

URL: http://svn.apache.org/viewvc?rev=430175&view=rev
Log:
[CONTINUUM-810] link up checking of continuum configuration to the actions
Submitted by: Jesse McConnell

Modified:
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AbstractNotifierEditAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddBuildDefinitionAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenOneProjectAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddNotifierAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddProjectAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddScheduleAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildDefinitionEditAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildProjectAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultsListAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/CheckConfigurationAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ConfigurationAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteBuildDefinitionAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteNotifierAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteProjectAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/EditScheduleAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/GroupSummaryAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/LoginAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectEditAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectViewAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ScheduleAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/SummaryAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyAction.java
    maven/continuum/trunk/continuum-webapp/src/main/resources/xwork.xml

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AbstractNotifierEditAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AbstractNotifierEditAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AbstractNotifierEditAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AbstractNotifierEditAction.java
Wed Aug  9 15:51:38 2006
@@ -19,7 +19,7 @@
 import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.ProjectNotifier;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
+import org.apache.maven.continuum.web.action.ContinuumActionSupport;
 
 import java.util.Map;
 
@@ -28,7 +28,7 @@
  * @version $Id$
  */
 public abstract class AbstractNotifierEditAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
     private Continuum continuum;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddBuildDefinitionAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddBuildDefinitionAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddBuildDefinitionAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddBuildDefinitionAction.java
Wed Aug  9 15:51:38 2006
@@ -16,11 +16,9 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.Project;
 import org.apache.maven.continuum.model.project.Schedule;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.util.Collection;
 import java.util.HashMap;
@@ -36,12 +34,8 @@
  *   role-hint="addBuildDefinition"
  */
 public class AddBuildDefinitionAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private Project project;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenOneProjectAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenOneProjectAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenOneProjectAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenOneProjectAction.java
Wed Aug  9 15:51:38 2006
@@ -20,7 +20,6 @@
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.codehaus.plexus.util.StringUtils;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.io.File;
 import java.net.MalformedURLException;
@@ -34,12 +33,8 @@
  *   role-hint="addMavenOneProject"
  */
 public class AddMavenOneProjectAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private String m1PomUrl;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddMavenTwoProjectAction.java
Wed Aug  9 15:51:38 2006
@@ -16,11 +16,9 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.codehaus.plexus.util.StringUtils;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.io.File;
 import java.net.MalformedURLException;
@@ -34,12 +32,8 @@
  *   role-hint="addMavenTwoProject"
  */
 public class AddMavenTwoProjectAction
-    extends PlexusActionSupport
-{
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
+    extends ContinuumActionSupport
+{    
 
     private String m2PomUrl;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddNotifierAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddNotifierAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddNotifierAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddNotifierAction.java
Wed Aug  9 15:51:38 2006
@@ -16,8 +16,6 @@
  * limitations under the License.
  */
 
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
-
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
  * @version $Id$
@@ -25,7 +23,7 @@
  * @plexus.component role="com.opensymphony.xwork.Action" role-hint="addNotifier"
  */
 public class AddNotifierAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
     private int projectId;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddProjectAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddProjectAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddProjectAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddProjectAction.java
Wed Aug  9 15:51:38 2006
@@ -16,10 +16,8 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.Project;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 /**
  * @author Nick Gonzalez
@@ -30,12 +28,8 @@
  *   role-hint="addProject"
  */
 public class AddProjectAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private String projectName;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddScheduleAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddScheduleAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddScheduleAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/AddScheduleAction.java
Wed Aug  9 15:51:38 2006
@@ -19,7 +19,7 @@
 import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.Schedule;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
+import org.apache.maven.continuum.web.action.ContinuumActionSupport;
 
 /**
  * @author Nik Gonzalez
@@ -29,12 +29,8 @@
  *   role-hint="addSchedule"
  */
 public class AddScheduleAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private boolean active = true;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildDefinitionEditAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildDefinitionEditAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildDefinitionEditAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildDefinitionEditAction.java
Wed Aug  9 15:51:38 2006
@@ -21,7 +21,6 @@
 import org.apache.maven.continuum.model.project.BuildDefinition;
 import org.apache.maven.continuum.model.project.Project;
 import org.apache.maven.continuum.model.project.Schedule;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.util.Collection;
 import java.util.HashMap;
@@ -37,12 +36,8 @@
  *   role-hint="buildDefinitionEdit"
  */
 public class BuildDefinitionEditAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private BuildDefinition bd;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildProjectAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildProjectAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildProjectAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildProjectAction.java
Wed Aug  9 15:51:38 2006
@@ -16,9 +16,7 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
@@ -29,12 +27,8 @@
  *   role-hint="buildProject"
  */
 public class BuildProjectAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private int projectId;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultAction.java
Wed Aug  9 15:51:38 2006
@@ -16,10 +16,8 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.BuildResult;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.util.List;
 
@@ -32,13 +30,9 @@
  *   role-hint="buildResult"
  */
 public class BuildResultAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
 
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private BuildResult buildResult;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultsListAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultsListAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultsListAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/BuildResultsListAction.java
Wed Aug  9 15:51:38 2006
@@ -16,9 +16,7 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.util.Collection;
 
@@ -31,13 +29,8 @@
  *   role-hint="buildResults"
  */
 public class BuildResultsListAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
-
     private Collection buildResults;
 
     private int projectId;

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/CheckConfigurationAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/CheckConfigurationAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/CheckConfigurationAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/CheckConfigurationAction.java
Wed Aug  9 15:51:38 2006
@@ -16,9 +16,6 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
-
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
  * @version $Id$
@@ -28,12 +25,8 @@
  *   role-hint="checkConfiguration"
  */
 public class CheckConfigurationAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     public String execute()
     {

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ConfigurationAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ConfigurationAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ConfigurationAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ConfigurationAction.java
Wed Aug  9 15:51:38 2006
@@ -90,7 +90,8 @@
 
         try
         {
-            continuum.getConfiguration().store();
+            continuum.getConfiguration().setInitialized( true );
+            continuum.getConfiguration().store();            
         }
         catch ( ConfigurationStoringException e )
         {

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteBuildDefinitionAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteBuildDefinitionAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteBuildDefinitionAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteBuildDefinitionAction.java
Wed Aug  9 15:51:38 2006
@@ -16,9 +16,7 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
@@ -29,13 +27,8 @@
  *   role-hint="deleteBuildDefinition"
  */
 public class DeleteBuildDefinitionAction
-    extends PlexusActionSupport
-{
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
-
+    extends ContinuumActionSupport
+{    
     private int projectId;
 
     private int buildDefinitionId;

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteNotifierAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteNotifierAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteNotifierAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteNotifierAction.java
Wed Aug  9 15:51:38 2006
@@ -18,7 +18,7 @@
 
 import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
+import org.apache.maven.continuum.web.action.ContinuumActionSupport;
 
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
@@ -29,12 +29,8 @@
  *   role-hint="deleteNotifier"
  */
 public class DeleteNotifierAction
-    extends PlexusActionSupport
-{
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
+    extends ContinuumActionSupport
+{    
 
     private int projectId;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteProjectAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteProjectAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteProjectAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/DeleteProjectAction.java
Wed Aug  9 15:51:38 2006
@@ -16,9 +16,7 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
@@ -29,13 +27,8 @@
  *   role-hint="deleteProject"
  */
 public class DeleteProjectAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
-
     private int projectId;
 
     private String projectName;

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/EditScheduleAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/EditScheduleAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/EditScheduleAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/EditScheduleAction.java
Wed Aug  9 15:51:38 2006
@@ -19,7 +19,6 @@
 import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.Schedule;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 /**
  * @author Nik Gonzalez
@@ -29,13 +28,8 @@
  *   role-hint="editSchedule"
  */
 public class EditScheduleAction
-    extends PlexusActionSupport
-{
-
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
+    extends ContinuumActionSupport
+{   
 
     private Schedule schedule;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/GroupSummaryAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/GroupSummaryAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/GroupSummaryAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/GroupSummaryAction.java
Wed Aug  9 15:51:38 2006
@@ -1,18 +1,16 @@
 package org.apache.maven.continuum.web.action;
 
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
-import org.apache.maven.continuum.Continuum;
-import org.apache.maven.continuum.web.model.ProjectSummary;
-import org.apache.maven.continuum.web.model.GroupSummary;
-import org.apache.maven.continuum.model.project.Project;
 import org.apache.maven.continuum.model.project.BuildResult;
+import org.apache.maven.continuum.model.project.Project;
 import org.apache.maven.continuum.model.project.ProjectGroup;
+import org.apache.maven.continuum.web.model.GroupSummary;
+import org.apache.maven.continuum.web.model.ProjectSummary;
 
-import java.util.List;
-import java.util.Collection;
-import java.util.Map;
 import java.util.ArrayList;
+import java.util.Collection;
 import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
 /*
  * Copyright 2005 The Codehaus.
  *
@@ -32,135 +30,118 @@
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
  * @version $Id$
- *
- * @plexus.component
- *   role="com.opensymphony.xwork.Action"
- *   role-hint="groupSummary"
+ * @plexus.component role="com.opensymphony.xwork.Action"
+ * role-hint="groupSummary"
  */
 public class GroupSummaryAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
-
-    
 
     private List groups;
 
     public String execute()
         throws Exception
     {
-        try
-        {
-            groups = new ArrayList();
+        groups = new ArrayList();
 
-            Collection projectGroups = continuum.getAllProjectGroupsWithProjects();
+        Collection projectGroups = continuum.getAllProjectGroupsWithProjects();
 
-            for ( Iterator j = projectGroups.iterator(); j.hasNext(); )
-            {
-                ProjectGroup projectGroup = (ProjectGroup) j.next();
+        for ( Iterator j = projectGroups.iterator(); j.hasNext(); )
+        {
+            ProjectGroup projectGroup = (ProjectGroup) j.next();
 
-                getLogger().info("GroupSummaryAction: building group " + projectGroup.getName()
);
+            getLogger().info( "GroupSummaryAction: building group " + projectGroup.getName()
);
 
-                GroupSummary groupModel = new GroupSummary();
-                groupModel.setId( projectGroup.getId() );
-                groupModel.setGroupId( projectGroup.getGroupId() );
-                groupModel.setName( projectGroup.getName() );
-                groupModel.setDescription( projectGroup.getDescription() );
+            GroupSummary groupModel = new GroupSummary();
+            groupModel.setId( projectGroup.getId() );
+            groupModel.setGroupId( projectGroup.getGroupId() );
+            groupModel.setName( projectGroup.getName() );
+            groupModel.setDescription( projectGroup.getDescription() );
 
-                //TODO: Create a summary jpox request so code will be more simple and performance
will be better
-                Collection projects = projectGroup.getProjects();
+            //TODO: Create a summary jpox request so code will be more simple and performance
will be better
+            Collection projects = projectGroup.getProjects();
 
-                Map buildResults = continuum.getLatestBuildResults();
+            Map buildResults = continuum.getLatestBuildResults();
 
-                Map buildResultsInSuccess = continuum.getBuildResultsInSuccess();
+            Map buildResultsInSuccess = continuum.getBuildResultsInSuccess();
 
-                List projectModels = new ArrayList();
-                int numSuccesses = 0;
-                int numFailures = 0;
-                int numErrors = 0;
+            List projectModels = new ArrayList();
+            int numSuccesses = 0;
+            int numFailures = 0;
+            int numErrors = 0;
 
-                for ( Iterator i = projects.iterator(); i.hasNext(); )
-                {
-                    Project project = (Project) i.next();
+            for ( Iterator i = projects.iterator(); i.hasNext(); )
+            {
+                Project project = (Project) i.next();
 
-                    ProjectSummary model = new ProjectSummary();
+                ProjectSummary model = new ProjectSummary();
 
-                    getLogger().info("GroupSummaryAction: building project model " + project.getName()
);
+                getLogger().info( "GroupSummaryAction: building project model " + project.getName()
);
 
-                    model.setId( project.getId() );
+                model.setId( project.getId() );
 
-                    model.setName( project.getName() );
+                model.setName( project.getName() );
 
-                    model.setVersion( project.getVersion() );
+                model.setVersion( project.getVersion() );
 
-                    model.setProjectGroupName( project.getProjectGroup().getName() );
+                model.setProjectGroupName( project.getProjectGroup().getName() );
 
-                    if ( continuum.isInBuildingQueue( project.getId() ) ||
-                        continuum.isInCheckoutQueue( project.getId() ) )
-                    {
-                        model.setInQueue( true );
-                    }
-                    else
-                    {
-                        model.setInQueue( false );
-                    }
+                if ( continuum.isInBuildingQueue( project.getId() ) || continuum.isInCheckoutQueue(
project.getId() ) )
+                {
+                    model.setInQueue( true );
+                }
+                else
+                {
+                    model.setInQueue( false );
+                }
 
-                    model.setState( project.getState() );
+                model.setState( project.getState() );
 
-                    if ( project.getState() == 2 )
-                    {
-                        numSuccesses++;
-                    }
-                    else if ( project.getState() == 3 )
-                    {
-                        numFailures++;
-                    }
-                    else if ( project.getState() == 4 )
-                    {
-                        numErrors++;
-                    }
+                if ( project.getState() == 2 )
+                {
+                    numSuccesses++;
+                }
+                else if ( project.getState() == 3 )
+                {
+                    numFailures++;
+                }
+                else if ( project.getState() == 4 )
+                {
+                    numErrors++;
+                }
 
-                    model.setBuildNumber( project.getBuildNumber() );
+                model.setBuildNumber( project.getBuildNumber() );
 
-                    if ( buildResultsInSuccess != null )
-                    {
-                        BuildResult buildInSuccess =
-                            (BuildResult) buildResultsInSuccess.get( new Integer( project.getId()
) );
+                if ( buildResultsInSuccess != null )
+                {
+                    BuildResult buildInSuccess =
+                        (BuildResult) buildResultsInSuccess.get( new Integer( project.getId()
) );
 
-                        if ( buildInSuccess != null )
-                        {
-                            model.setBuildInSuccessId( buildInSuccess.getId() );
-                        }
+                    if ( buildInSuccess != null )
+                    {
+                        model.setBuildInSuccessId( buildInSuccess.getId() );
                     }
+                }
 
-                    if ( buildResults != null )
-                    {
-                        BuildResult latestBuild = (BuildResult) buildResults.get( new Integer(
project.getId() ) );
+                if ( buildResults != null )
+                {
+                    BuildResult latestBuild = (BuildResult) buildResults.get( new Integer(
project.getId() ) );
 
-                        if ( latestBuild != null )
-                        {
-                            model.setLatestBuildId( latestBuild.getId() );
-                        }
+                    if ( latestBuild != null )
+                    {
+                        model.setLatestBuildId( latestBuild.getId() );
                     }
-                    getLogger().info( "GroupSummaryAction: adding model to group " + model.getName()
);
-                    projectModels.add( model );
                 }
-
-                groupModel.setNumSuccesses( numSuccesses );
-                groupModel.setNumFailures( numFailures );
-                groupModel.setNumErrors( numErrors );
-                groupModel.setProjects( projectModels );
-                getLogger().info( "GroupSummaryAction: adding group to groups list " + groupModel.getName()
);
-                groups.add( groupModel );
+                getLogger().info( "GroupSummaryAction: adding model to group " + model.getName()
);
+                projectModels.add( model );
             }
 
-        }
-        catch ( Exception e )
-        {
-            e.printStackTrace();
+            groupModel.setNumSuccesses( numSuccesses );
+            groupModel.setNumFailures( numFailures );
+            groupModel.setNumErrors( numErrors );
+            groupModel.setProjects( projectModels );
+            getLogger().info( "GroupSummaryAction: adding group to groups list " + groupModel.getName()
);
+            groups.add( groupModel );
         }
 
         return SUCCESS;

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/LoginAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/LoginAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/LoginAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/LoginAction.java
Wed Aug  9 15:51:38 2006
@@ -1,7 +1,5 @@
 package org.apache.maven.continuum.web.action;
 
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
-
 /*
  * Copyright 2004-2005 The Apache Software Foundation.
  *
@@ -27,7 +25,7 @@
  *   role-hint="login"
  */
 public class LoginAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
     private String username = "";
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectEditAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectEditAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectEditAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectEditAction.java
Wed Aug  9 15:51:38 2006
@@ -16,10 +16,8 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.Project;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
@@ -30,12 +28,8 @@
  *   role-hint="projectEdit"
  */
 public class ProjectEditAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private Project project;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectViewAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectViewAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectViewAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ProjectViewAction.java
Wed Aug  9 15:51:38 2006
@@ -16,10 +16,8 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.model.project.Project;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 /**
  * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
@@ -30,12 +28,8 @@
  *   role-hint="projectView"
  */
 public class ProjectViewAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private Project project;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ScheduleAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ScheduleAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ScheduleAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/ScheduleAction.java
Wed Aug  9 15:51:38 2006
@@ -16,9 +16,7 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.util.Collection;
 
@@ -30,12 +28,8 @@
  *   role-hint="schedules"
  */
 public class ScheduleAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
 
     private Collection schedules;
 

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/SummaryAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/SummaryAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/SummaryAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/SummaryAction.java
Wed Aug  9 15:51:38 2006
@@ -16,11 +16,9 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.model.project.BuildResult;
 import org.apache.maven.continuum.model.project.Project;
 import org.apache.maven.continuum.web.model.ProjectSummary;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
 
 import java.util.ArrayList;
 import java.util.Collection;
@@ -37,13 +35,8 @@
  *   role-hint="summary"
  */
 public class SummaryAction
-    extends PlexusActionSupport
-{
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
-
+    extends ContinuumActionSupport
+{    
     private int projectGroupId = -1;
 
     private int nbSuccesses;

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyAction.java?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyAction.java
Wed Aug  9 15:51:38 2006
@@ -19,7 +19,7 @@
 import org.apache.maven.continuum.Continuum;
 import org.apache.maven.continuum.ContinuumException;
 import org.apache.maven.continuum.web.util.WorkingCopyContentGenerator;
-import org.codehaus.plexus.xwork.action.PlexusActionSupport;
+import org.apache.maven.continuum.web.action.ContinuumActionSupport;
 
 import com.opensymphony.webwork.ServletActionContext;
 import com.opensymphony.webwork.views.util.UrlHelper;
@@ -36,13 +36,8 @@
  *   role-hint="workingCopy"
  */
 public class WorkingCopyAction
-    extends PlexusActionSupport
+    extends ContinuumActionSupport
 {
-    /**
-     * @plexus.requirement
-     */
-    private Continuum continuum;
-
     /**
      * @plexus.requirement
      */

Modified: maven/continuum/trunk/continuum-webapp/src/main/resources/xwork.xml
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/resources/xwork.xml?rev=430175&r1=430174&r2=430175&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/resources/xwork.xml (original)
+++ maven/continuum/trunk/continuum-webapp/src/main/resources/xwork.xml Wed Aug  9 15:51:38
2006
@@ -6,6 +6,7 @@
 
     <interceptors>
       <interceptor-stack name="defaultContinuumStack">
+        <interceptor-ref name="exception"/>
         <interceptor-ref name="prepare"/>
         <interceptor-ref name="servlet-config"/>
         <interceptor-ref name="chain"/>
@@ -23,8 +24,14 @@
     <default-interceptor-ref name="defaultContinuumStack"/>
 
     <global-results>
-      <result name="error">error.jsp</result>
+      <result name="continuumException">error.jsp</result>
+      <result name="continuumInitialization" type="redirect">/configuration!input.action</result>
     </global-results>
+
+    <global-exception-mappings>
+      <exception-mapping exception="org.apache.maven.continuum.ContinuumException" result="continuumException"/>
+      <exception-mapping exception="org.apache.maven.continuum.initialization.ContinuumInitializationException"
result="continuumInitialization"/>
+    </global-exception-mappings>
 
     <action name="checkConfiguration" class="checkConfiguration">
       <result name="input">/redirectToContinuumInitialization.jsp</result>



Mime
View raw message