continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From br...@apache.org
Subject svn commit: r232766 - in /maven/continuum/trunk: continuum-api/src/main/java/org/apache/maven/continuum/ continuum-cc/src/main/java/org/apache/maven/continuum/project/builder/cc/ continuum-core-it/src/test/java/org/apache/maven/continuum/it/ continuum-...
Date Mon, 15 Aug 2005 06:33:41 GMT
Author: brett
Date: Sun Aug 14 23:33:10 2005
New Revision: 232766

URL: http://svn.apache.org/viewcvs?rev=232766&view=rev
Log:
merge maven2 project into main project
fix some issues with not creating projects correctly

Modified:
    maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/Continuum.java
    maven/continuum/trunk/continuum-cc/src/main/java/org/apache/maven/continuum/project/builder/cc/CruiseControlProjectBuilder.java
    maven/continuum/trunk/continuum-core-it/src/test/java/org/apache/maven/continuum/it/ContinuumXmlRpcClient.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m1/DefaultMavenOneMetadataHelper.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenBuilderHelper.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenTwoBuildExecutor.java
    maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilder.java
    maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/DefaultContinuumTest.java
    maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilderTest.java
    maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo
    maven/continuum/trunk/continuum-model/src/main/resources/META-INF/package.jdo
    maven/continuum/trunk/continuum-web/src/main/resources/forms/mavenTwoProject.xml
    maven/continuum/trunk/continuum-xmlrpc/src/main/java/org/apache/maven/continuum/xmlrpc/DefaultContinuumXmlRpc.java

Modified: maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/Continuum.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/Continuum.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/Continuum.java
(original)
+++ maven/continuum/trunk/continuum-api/src/main/java/org/apache/maven/continuum/Continuum.java
Sun Aug 14 23:33:10 2005
@@ -21,7 +21,6 @@
 import org.apache.maven.continuum.model.scm.ScmResult;
 import org.apache.maven.continuum.project.ContinuumBuildSettings;
 import org.apache.maven.continuum.project.ContinuumProject;
-import org.apache.maven.continuum.project.MavenTwoProject;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.codehaus.plexus.util.dag.CycleDetectedException;
 
@@ -101,15 +100,6 @@
     // ----------------------------------------------------------------------
 
     ContinuumProjectBuildingResult addMavenTwoProject( String metadataUrl )
-        throws ContinuumException;
-
-    String addMavenTwoProject( MavenTwoProject project )
-        throws ContinuumException;
-
-    MavenTwoProject getMavenTwoProject( String id )
-        throws ContinuumException;
-
-    void updateMavenTwoProject( MavenTwoProject project )
         throws ContinuumException;
 
     // ----------------------------------------------------------------------

Modified: maven/continuum/trunk/continuum-cc/src/main/java/org/apache/maven/continuum/project/builder/cc/CruiseControlProjectBuilder.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-cc/src/main/java/org/apache/maven/continuum/project/builder/cc/CruiseControlProjectBuilder.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-cc/src/main/java/org/apache/maven/continuum/project/builder/cc/CruiseControlProjectBuilder.java
(original)
+++ maven/continuum/trunk/continuum-cc/src/main/java/org/apache/maven/continuum/project/builder/cc/CruiseControlProjectBuilder.java
Sun Aug 14 23:33:10 2005
@@ -17,6 +17,7 @@
  */
 
 import org.apache.maven.continuum.execution.ContinuumBuildExecutor;
+import org.apache.maven.continuum.model.project.BuildDefinition;
 import org.apache.maven.continuum.model.project.ProjectNotifier;
 import org.apache.maven.continuum.project.ContinuumProject;
 import org.apache.maven.continuum.project.builder.AbstractContinuumProjectBuilder;
@@ -171,6 +172,13 @@
                 project = new ContinuumProject();
 
                 project.setExecutorId( ContinuumBuildExecutor.ANT_EXECUTOR_ID );
+
+                // TODO: shared construction of the default build definition
+                BuildDefinition bd = new BuildDefinition();
+                bd.setArguments( "" );
+                bd.setGoals( "clean build" );
+                bd.setBuildFile( "build.xml" );
+                project.addBuildDefinition( bd );
             }
             else if ( child.getName().equals( "maven" ) )
             {
@@ -183,6 +191,13 @@
                 project = new ContinuumProject();
 
                 project.setExecutorId( ContinuumBuildExecutor.MAVEN_ONE_EXECUTOR_ID );
+
+                // TODO: shared construction of the default build definition
+                BuildDefinition bd = new BuildDefinition();
+                bd.setArguments( "" );
+                bd.setGoals( "clean:clean jar:install" );
+                bd.setBuildFile( "project.xml" );
+                project.addBuildDefinition( bd );
             }
             else
             {

Modified: maven/continuum/trunk/continuum-core-it/src/test/java/org/apache/maven/continuum/it/ContinuumXmlRpcClient.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core-it/src/test/java/org/apache/maven/continuum/it/ContinuumXmlRpcClient.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core-it/src/test/java/org/apache/maven/continuum/it/ContinuumXmlRpcClient.java
(original)
+++ maven/continuum/trunk/continuum-core-it/src/test/java/org/apache/maven/continuum/it/ContinuumXmlRpcClient.java
Sun Aug 14 23:33:10 2005
@@ -22,7 +22,6 @@
 import org.apache.maven.continuum.model.project.ProjectNotifier;
 import org.apache.maven.continuum.model.scm.ScmResult;
 import org.apache.maven.continuum.project.ContinuumProject;
-import org.apache.maven.continuum.project.MavenTwoProject;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.apache.maven.continuum.xmlrpc.XmlRpcHelper;
 import org.apache.xmlrpc.XmlRpcClient;
@@ -189,24 +188,6 @@
     // ----------------------------------------------------------------------
 
     public ContinuumProjectBuildingResult addMavenTwoProject( String metadataUrl )
-        throws ContinuumException
-    {
-        throw new UnsupportedOperationException();
-    }
-
-    public String addMavenTwoProject( MavenTwoProject mavenTwoProject )
-        throws ContinuumException
-    {
-        throw new UnsupportedOperationException();
-    }
-
-    public MavenTwoProject getMavenTwoProject( String projectId )
-        throws ContinuumException
-    {
-        throw new UnsupportedOperationException();
-    }
-
-    public void updateMavenTwoProject( MavenTwoProject mavenTwoProject )
         throws ContinuumException
     {
         throw new UnsupportedOperationException();

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
Sun Aug 14 23:33:10 2005
@@ -36,7 +36,6 @@
 import org.apache.maven.continuum.model.scm.ScmResult;
 import org.apache.maven.continuum.project.ContinuumBuildSettings;
 import org.apache.maven.continuum.project.ContinuumProject;
-import org.apache.maven.continuum.project.MavenTwoProject;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.apache.maven.continuum.project.builder.maven.MavenOneContinuumProjectBuilder;
 import org.apache.maven.continuum.project.builder.maven.MavenTwoContinuumProjectBuilder;
@@ -357,26 +356,6 @@
     {
         return executeAddProjectsFromMetadataActivity( metadataUrl, MavenTwoContinuumProjectBuilder.ID,
                                                        MavenTwoBuildExecutor.ID );
-    }
-
-    public String addMavenTwoProject( MavenTwoProject project )
-        throws ContinuumException
-    {
-        project.setExecutorId( MavenTwoBuildExecutor.ID );
-
-        return executeAddProjectFromScmActivity( project );
-    }
-
-    public MavenTwoProject getMavenTwoProject( String projectId )
-        throws ContinuumException
-    {
-        return (MavenTwoProject) getProject( projectId );
-    }
-
-    public void updateMavenTwoProject( MavenTwoProject project )
-        throws ContinuumException
-    {
-        updateProject( (ContinuumProject) project );
     }
 
     // ----------------------------------------------------------------------

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m1/DefaultMavenOneMetadataHelper.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m1/DefaultMavenOneMetadataHelper.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m1/DefaultMavenOneMetadataHelper.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m1/DefaultMavenOneMetadataHelper.java
Sun Aug 14 23:33:10 2005
@@ -16,6 +16,7 @@
  * limitations under the License.
  */
 
+import org.apache.maven.continuum.model.project.BuildDefinition;
 import org.apache.maven.continuum.model.project.ProjectNotifier;
 import org.apache.maven.continuum.notification.ContinuumRecipientSource;
 import org.apache.maven.continuum.project.ContinuumProject;
@@ -239,6 +240,12 @@
         project.setScmUrl( scmConnection );
 
         project.setNotifiers( notifiers );
+
+        BuildDefinition bd = new BuildDefinition();
+        bd.setArguments( "" );
+        bd.setGoals( "clean:clean jar:install" );
+        bd.setBuildFile( "project.xml" );
+        project.addBuildDefinition( bd );
     }
 
     // ----------------------------------------------------------------------

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/DefaultMavenBuilderHelper.java
Sun Aug 14 23:33:10 2005
@@ -19,10 +19,11 @@
 import org.apache.maven.artifact.repository.ArtifactRepository;
 import org.apache.maven.artifact.repository.ArtifactRepositoryFactory;
 import org.apache.maven.artifact.repository.layout.ArtifactRepositoryLayout;
+import org.apache.maven.continuum.model.project.BuildDefinition;
 import org.apache.maven.continuum.model.project.ProjectDependency;
 import org.apache.maven.continuum.model.project.ProjectDeveloper;
 import org.apache.maven.continuum.model.project.ProjectNotifier;
-import org.apache.maven.continuum.project.MavenTwoProject;
+import org.apache.maven.continuum.project.ContinuumProject;
 import org.apache.maven.model.CiManagement;
 import org.apache.maven.model.Dependency;
 import org.apache.maven.model.Developer;
@@ -82,13 +83,13 @@
     // MavenBuilderHelper Implementation
     // ----------------------------------------------------------------------
 
-    public void mapMetadataToProject( File metadata, MavenTwoProject continuumProject )
+    public void mapMetadataToProject( File metadata, ContinuumProject continuumProject )
         throws MavenBuilderHelperException
     {
         mapMavenProjectToContinuumProject( getMavenProject( metadata ), continuumProject
);
     }
 
-    public void mapMavenProjectToContinuumProject( MavenProject mavenProject, MavenTwoProject
continuumProject )
+    public void mapMavenProjectToContinuumProject( MavenProject mavenProject, ContinuumProject
continuumProject )
         throws MavenBuilderHelperException
     {
         continuumProject.setName( getProjectName( mavenProject ) );
@@ -97,19 +98,11 @@
 
         continuumProject.setVersion( getVersion( mavenProject ) );
 
-        if ( StringUtils.isEmpty( continuumProject.getCommandLineArguments() ) )
-        {
-            // ----------------------------------------------------------------------
-            // Run in non-interactive mode and non-recursive mode
-            // ----------------------------------------------------------------------
-
-            continuumProject.setCommandLineArguments( "-N -B" );
-        }
-
-        if ( StringUtils.isEmpty( continuumProject.getGoals() ) )
-        {
-            continuumProject.setGoals( "clean:clean install" );
-        }
+        BuildDefinition bd = new BuildDefinition();
+        bd.setArguments( "--batch-mode --non-recursive" );
+        bd.setGoals( "clean:clean install" );
+        bd.setBuildFile( "pom.xml" );
+        continuumProject.addBuildDefinition( bd );
 
         // ----------------------------------------------------------------------
         // GroupId

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenBuilderHelper.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenBuilderHelper.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenBuilderHelper.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenBuilderHelper.java
Sun Aug 14 23:33:10 2005
@@ -16,7 +16,7 @@
  * limitations under the License.
  */
 
-import org.apache.maven.continuum.project.MavenTwoProject;
+import org.apache.maven.continuum.project.ContinuumProject;
 import org.apache.maven.project.MavenProject;
 
 import java.io.File;
@@ -29,12 +29,12 @@
 {
     String ROLE = MavenBuilderHelper.class.getName();
 
-    void mapMetadataToProject( File metadata, MavenTwoProject project )
+    void mapMetadataToProject( File metadata, ContinuumProject project )
         throws MavenBuilderHelperException;
 
     MavenProject getMavenProject( File file )
         throws MavenBuilderHelperException;
 
-    void mapMavenProjectToContinuumProject( MavenProject mavenProject, MavenTwoProject continuumProject
)
+    void mapMavenProjectToContinuumProject( MavenProject mavenProject, ContinuumProject continuumProject
)
         throws MavenBuilderHelperException;
 }

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenTwoBuildExecutor.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenTwoBuildExecutor.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenTwoBuildExecutor.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/execution/maven/m2/MavenTwoBuildExecutor.java
Sun Aug 14 23:33:10 2005
@@ -22,7 +22,6 @@
 import org.apache.maven.continuum.execution.ContinuumBuildExecutorException;
 import org.apache.maven.continuum.model.project.BuildDefinition;
 import org.apache.maven.continuum.project.ContinuumProject;
-import org.apache.maven.continuum.project.MavenTwoProject;
 import org.codehaus.plexus.util.StringUtils;
 
 import java.io.File;
@@ -69,18 +68,14 @@
                                                 File buildOutput )
         throws ContinuumBuildExecutorException
     {
-        return build( project, buildOutput );
-    }
-
-    public ContinuumBuildExecutionResult build( ContinuumProject p, File buildOutput )
-        throws ContinuumBuildExecutorException
-    {
-        MavenTwoProject project = (MavenTwoProject) p;
+        // TODO: get from installation
+//        String executable = project.getExecutable();
+        String executable = "m2";
 
-        String arguments = StringUtils.clean( project.getCommandLineArguments() ) + " " +
-            StringUtils.clean( project.getGoals() );
+        String arguments = StringUtils.clean( buildDefinition.getArguments() ) + " " +
+            StringUtils.clean( buildDefinition.getGoals() );
 
-        return executeShellCommand( project, null, arguments, buildOutput );
+        return executeShellCommand( project, executable, arguments, buildOutput );
     }
 
     public void updateProjectFromCheckOut( File workingDirectory, ContinuumProject project
)
@@ -90,7 +85,7 @@
 
         try
         {
-            builderHelper.mapMetadataToProject( f, (MavenTwoProject) project );
+            builderHelper.mapMetadataToProject( f, project );
         }
         catch ( MavenBuilderHelperException e )
         {

Modified: maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilder.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilder.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilder.java
(original)
+++ maven/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilder.java
Sun Aug 14 23:33:10 2005
@@ -20,7 +20,7 @@
 import org.apache.maven.continuum.execution.maven.m2.MavenBuilderHelperException;
 import org.apache.maven.continuum.execution.maven.m2.MavenTwoBuildExecutor;
 import org.apache.maven.continuum.model.project.ProjectGroup;
-import org.apache.maven.continuum.project.MavenTwoProject;
+import org.apache.maven.continuum.project.ContinuumProject;
 import org.apache.maven.continuum.project.builder.AbstractContinuumProjectBuilder;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuilder;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuilderException;
@@ -114,7 +114,7 @@
 
         if ( !excludedPackagingTypes.contains( mavenProject.getPackaging() ) )
         {
-            MavenTwoProject continuumProject = new MavenTwoProject();
+            ContinuumProject continuumProject = new ContinuumProject();
 
             try
             {

Modified: maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/DefaultContinuumTest.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/DefaultContinuumTest.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/DefaultContinuumTest.java
(original)
+++ maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/DefaultContinuumTest.java
Sun Aug 14 23:33:10 2005
@@ -17,7 +17,6 @@
  */
 
 import org.apache.maven.continuum.project.ContinuumProject;
-import org.apache.maven.continuum.project.MavenTwoProject;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.codehaus.plexus.taskqueue.TaskQueue;
 import org.codehaus.plexus.taskqueue.execution.TaskQueueExecutor;
@@ -117,16 +116,14 @@
 
         assertEquals( 1, projects.size() );
 
-        assertEquals( MavenTwoProject.class, projects.get( 0 ).getClass() );
+        assertEquals( ContinuumProject.class, projects.get( 0 ).getClass() );
 
-        MavenTwoProject project = (MavenTwoProject) projects.get( 0 );
+        ContinuumProject project = (ContinuumProject) projects.get( 0 );
 
         project.setName( project.getName() + " 2" );
 
-        project.setCommandLineArguments( null );
+        continuum.updateProject( project );
 
-        continuum.updateMavenTwoProject( project );
-
-        project = continuum.getMavenTwoProject( project.getId() );
+        project = continuum.getProject( project.getId() );
     }
 }

Modified: maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilderTest.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilderTest.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilderTest.java
(original)
+++ maven/continuum/trunk/continuum-core/src/test/java/org/apache/maven/continuum/project/builder/maven/MavenTwoContinuumProjectBuilderTest.java
Sun Aug 14 23:33:10 2005
@@ -18,7 +18,7 @@
 
 import org.apache.maven.continuum.model.project.ProjectGroup;
 import org.apache.maven.continuum.model.project.ProjectNotifier;
-import org.apache.maven.continuum.project.MavenTwoProject;
+import org.apache.maven.continuum.project.ContinuumProject;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuilder;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.codehaus.plexus.PlexusTestCase;
@@ -56,7 +56,7 @@
 
         assertEquals( 1, result.getProjects().size() );
 
-        MavenTwoProject project = (MavenTwoProject) result.getProjects().get( 0 );
+        ContinuumProject project = (ContinuumProject) result.getProjects().get( 0 );
 
         assertNotNull( project.getNotifiers() );
 
@@ -87,7 +87,7 @@
 
         assertEquals( 1, result.getProjects().size() );
 
-        MavenTwoProject project = (MavenTwoProject) result.getProjects().get( 0 );
+        ContinuumProject project = (ContinuumProject) result.getProjects().get( 0 );
 
         assertNotNull( project.getNotifiers() );
 
@@ -160,7 +160,7 @@
 
         for ( Iterator it = result.getProjects().iterator(); it.hasNext(); )
         {
-            MavenTwoProject project = (MavenTwoProject) it.next();
+            ContinuumProject project = (ContinuumProject) it.next();
 
             assertNotNull( project.getName() );
 
@@ -180,7 +180,7 @@
 
     private void assertMavenTwoProject( String name, Map projects )
     {
-        MavenTwoProject project = (MavenTwoProject) projects.get( name );
+        ContinuumProject project = (ContinuumProject) projects.get( name );
 
         assertNotNull( project );
 
@@ -189,7 +189,5 @@
         String scmUrl = "scm:svn:http://svn.apache.org/repos/asf/maven/continuum/trunk";
 
         assertTrue( project.getScmUrl().startsWith( scmUrl ) );
-
-        assertEquals( "clean:clean install", project.getGoals() );
     }
 }

Modified: maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo (original)
+++ maven/continuum/trunk/continuum-model/src/main/mdo/continuum.mdo Sun Aug 14 23:33:10 2005
@@ -848,25 +848,6 @@
       </fields>
     </class>
 
-    <class stash.storable="true">
-      <packageName>org.apache.maven.continuum.project</packageName>
-      <name>MavenTwoProject</name>
-      <version>1.0.0</version>
-      <superClass>ContinuumProject</superClass>
-      <fields>
-        <field>
-          <name>goals</name>
-          <version>1.0.0</version>
-          <type>String</type>
-        </field>
-        <field>
-          <name>commandLineArguments</name>
-          <version>1.0.0</version>
-          <type>String</type>
-        </field>
-      </fields>
-    </class>
-
     <class>
       <packageName>org.apache.maven.continuum.project</packageName>
       <name>ContinuumBuildSettings</name>

Modified: maven/continuum/trunk/continuum-model/src/main/resources/META-INF/package.jdo
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-model/src/main/resources/META-INF/package.jdo?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-model/src/main/resources/META-INF/package.jdo (original)
+++ maven/continuum/trunk/continuum-model/src/main/resources/META-INF/package.jdo Sun Aug
14 23:33:10 2005
@@ -59,15 +59,6 @@
         <field name="buildDefinitions"/>
       </fetch-group>
     </class>
-
-    <class name="MavenTwoProject" persistence-capable-superclass="org.apache.maven.continuum.project.ContinuumProject"
-           detachable="true">
-      <inheritance strategy="new-table"/>
-      <field name="commandLineArguments" persistence-modifier="persistent"/>
-      <field name="goals" persistence-modifier="persistent">
-        <column name="M2_GOALS"/>
-      </field>
-    </class>
     <class name="ContinuumBuildSettings" detachable="true">
       <field name="name" persistence-modifier="persistent"/>
       <field name="cronExpression" persistence-modifier="persistent"/>

Modified: maven/continuum/trunk/continuum-web/src/main/resources/forms/mavenTwoProject.xml
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-web/src/main/resources/forms/mavenTwoProject.xml?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-web/src/main/resources/forms/mavenTwoProject.xml (original)
+++ maven/continuum/trunk/continuum-web/src/main/resources/forms/mavenTwoProject.xml Sun Aug
14 23:33:10 2005
@@ -1,20 +1,22 @@
 <form>
   <extend>continuumProject</extend>
   <id>maven2Project</id>
-  <target-class>org.apache.maven.continuum.project.MavenTwoProject</target-class>
-  <lookup-expression>getMavenTwoProject(#id)</lookup-expression>
+  <target-class>org.apache.maven.continuum.project.ContinuumProject</target-class>
+  <lookup-expression>getProject(#id)</lookup-expression>
   <elements>
-    <element>
-      <id>project.phase</id>
-      <validators>
-        <validator>
-          <id>required</id>
-          <error-message-key>project.phase.error</error-message-key>
-        </validator>
-      </validators>
-      <expression>goals</expression>
-      <type>text</type>
-    </element>
+    <!-- TODO: build definition
+        <element>
+          <id>project.phase</id>
+          <validators>
+            <validator>
+              <id>required</id>
+              <error-message-key>project.phase.error</error-message-key>
+            </validator>
+          </validators>
+          <expression>goals</expression>
+          <type>text</type>
+        </element>
+    -->
   </elements>
 
   <!-- Add -->
@@ -23,18 +25,7 @@
     <action>addEntity</action>
     <view>Summary.vm</view>
     <view-on-failure>Add.vm</view-on-failure>
-    <fid-on-failure>maven2Project</fid-on-failure>    
-    <expression>addMavenTwoProject(#entity)</expression>
-  </add>
-
-  <!-- Update -->
-  <update>
-    <title-key>project.title.update</title-key>
-    <action>updateEntity</action>
-    <view>Summary.vm</view>
-    <view-on-failure>Edit.vm</view-on-failure>
     <fid-on-failure>maven2Project</fid-on-failure>
-    <expression>updateMavenTwoProject(#entity)</expression>
-  </update>
-
+    <expression>addProject(#entity,"maven-two")</expression>
+  </add>
 </form>

Modified: maven/continuum/trunk/continuum-xmlrpc/src/main/java/org/apache/maven/continuum/xmlrpc/DefaultContinuumXmlRpc.java
URL: http://svn.apache.org/viewcvs/maven/continuum/trunk/continuum-xmlrpc/src/main/java/org/apache/maven/continuum/xmlrpc/DefaultContinuumXmlRpc.java?rev=232766&r1=232765&r2=232766&view=diff
==============================================================================
--- maven/continuum/trunk/continuum-xmlrpc/src/main/java/org/apache/maven/continuum/xmlrpc/DefaultContinuumXmlRpc.java
(original)
+++ maven/continuum/trunk/continuum-xmlrpc/src/main/java/org/apache/maven/continuum/xmlrpc/DefaultContinuumXmlRpc.java
Sun Aug 14 23:33:10 2005
@@ -21,7 +21,6 @@
 import org.apache.maven.continuum.execution.shell.ShellBuildExecutor;
 import org.apache.maven.continuum.model.scm.ScmResult;
 import org.apache.maven.continuum.project.ContinuumProject;
-import org.apache.maven.continuum.project.MavenTwoProject;
 import org.apache.maven.continuum.project.builder.ContinuumProjectBuildingResult;
 import org.codehaus.plexus.logging.AbstractLogEnabled;
 import org.codehaus.plexus.util.StringUtils;
@@ -174,11 +173,11 @@
     {
         try
         {
-            MavenTwoProject project = new MavenTwoProject();
+            ContinuumProject project = new ContinuumProject();
 
             xmlRpcHelper.hashtableToObject( mavenTwoProject, project );
 
-            String projectId = continuum.addMavenTwoProject( project );
+            String projectId = continuum.addProject( project, ContinuumBuildExecutor.MAVEN_TWO_EXECUTOR_ID
);
 
             Collection projectIds = new Vector();
 
@@ -198,11 +197,11 @@
 
         try
         {
-            MavenTwoProject project = continuum.getMavenTwoProject( id );
+            ContinuumProject project = continuum.getProject( id );
 
             xmlRpcHelper.hashtableToObject( mavenTwoProject, project );
 
-            continuum.updateMavenTwoProject( project );
+            continuum.updateProject( project );
 
             return makeHashtable();
         }



Mime
View raw message