continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From br...@apache.org
Subject svn commit: r481456 - in /maven/continuum/trunk: ./ continuum-configuration/src/main/java/org/apache/maven/continuum/configuration/ continuum-configuration/src/main/mdo/ continuum-webapp/ continuum-webapp/src/main/java/org/apache/maven/continuum/web/ac...
Date Sat, 02 Dec 2006 00:26:34 GMT
Author: brett
Date: Fri Dec  1 16:26:32 2006
New Revision: 481456

URL: http://svn.apache.org/viewvc?view=rev&rev=481456
Log:
use shared app configuration

Removed:
    maven/continuum/trunk/continuum-configuration/src/main/java/org/apache/maven/continuum/configuration/ConfigurationChangeException.java
    maven/continuum/trunk/continuum-configuration/src/main/java/org/apache/maven/continuum/configuration/ConfigurationChangeListener.java
    maven/continuum/trunk/continuum-configuration/src/main/java/org/apache/maven/continuum/configuration/ConfigurationStore.java
    maven/continuum/trunk/continuum-configuration/src/main/java/org/apache/maven/continuum/configuration/ConfigurationStoreException.java
    maven/continuum/trunk/continuum-configuration/src/main/java/org/apache/maven/continuum/configuration/DefaultConfigurationStore.java
    maven/continuum/trunk/continuum-configuration/src/main/java/org/apache/maven/continuum/configuration/InvalidConfigurationException.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/CompanyPomHandler.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/DefaultCompanyPomHandler.java
    maven/continuum/trunk/continuum-webapp/src/test/java/org/apache/maven/continuum/TestSettingsBuilder.java
    maven/continuum/trunk/continuum-webapp/src/test/java/org/apache/maven/continuum/web/action/admin/
    maven/continuum/trunk/continuum-webapp/src/test/resources/org/
Modified:
    maven/continuum/trunk/continuum-configuration/src/main/mdo/configuration.mdo
    maven/continuum/trunk/continuum-webapp/pom.xml
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/ConfigureAppearanceAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/EditPomAction.java
    maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/component/CompanyInfoAction.java
    maven/continuum/trunk/pom.xml

Modified: maven/continuum/trunk/continuum-configuration/src/main/mdo/configuration.mdo
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-configuration/src/main/mdo/configuration.mdo?view=diff&rev=481456&r1=481455&r2=481456
==============================================================================
--- maven/continuum/trunk/continuum-configuration/src/main/mdo/configuration.mdo (original)
+++ maven/continuum/trunk/continuum-configuration/src/main/mdo/configuration.mdo Fri Dec 
1 16:26:32 2006
@@ -34,30 +34,7 @@
       <name>Configuration</name>
       <version>1.1.0+</version>
       <fields>
-        <field>
-          <name>companyPom</name>
-          <version>1.1.0+</version>
-          <description>The identifier of the company super POM.</description>
-          <association>
-            <type>CompanyPom</type>
-          </association>
-        </field>
-      </fields>
-    </class>
-    <class>
-      <name>CompanyPom</name>
-      <version>1.1.0+</version>
-      <fields>
-        <field>
-          <name>groupId</name>
-          <type>String</type>
-          <version>1.1.0+</version>
-        </field>
-        <field>
-          <name>artifactId</name>
-          <type>String</type>
-          <version>1.1.0+</version>
-        </field>
+        <!-- Reserved for future configuration -->
       </fields>
     </class>
   </classes>

Modified: maven/continuum/trunk/continuum-webapp/pom.xml
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/pom.xml?view=diff&rev=481456&r1=481455&r2=481456
==============================================================================
--- maven/continuum/trunk/continuum-webapp/pom.xml (original)
+++ maven/continuum/trunk/continuum-webapp/pom.xml Fri Dec  1 16:26:32 2006
@@ -203,6 +203,14 @@
       <artifactId>continuum-configuration</artifactId>
     </dependency>
     <dependency>
+      <groupId>org.apache.maven.shared</groupId>
+      <artifactId>maven-app-configuration-model</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.maven.shared</groupId>
+      <artifactId>maven-app-configuration-web</artifactId>
+    </dependency>
+    <dependency>
       <groupId>org.apache.maven.continuum</groupId>
       <artifactId>continuum-core</artifactId>
     </dependency>

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/ConfigureAppearanceAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/ConfigureAppearanceAction.java?view=diff&rev=481456&r1=481455&r2=481456
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/ConfigureAppearanceAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/ConfigureAppearanceAction.java
Fri Dec  1 16:26:32 2006
@@ -21,15 +21,17 @@
 
 import com.opensymphony.xwork.ModelDriven;
 import org.apache.maven.artifact.metadata.ArtifactMetadataRetrievalException;
-import org.apache.maven.continuum.configuration.Configuration;
-import org.apache.maven.continuum.configuration.ConfigurationChangeException;
-import org.apache.maven.continuum.configuration.ConfigurationStore;
-import org.apache.maven.continuum.configuration.ConfigurationStoreException;
-import org.apache.maven.continuum.configuration.InvalidConfigurationException;
+import org.apache.maven.continuum.execution.maven.m2.MavenBuilderHelper;
 import org.apache.maven.continuum.security.ContinuumRoleConstants;
 import org.apache.maven.continuum.web.action.ContinuumActionSupport;
 import org.apache.maven.model.Model;
 import org.apache.maven.project.ProjectBuildingException;
+import org.apache.maven.shared.app.company.CompanyPomHandler;
+import org.apache.maven.shared.app.configuration.Configuration;
+import org.apache.maven.shared.app.configuration.ConfigurationChangeException;
+import org.apache.maven.shared.app.configuration.ConfigurationStore;
+import org.apache.maven.shared.app.configuration.ConfigurationStoreException;
+import org.apache.maven.shared.app.configuration.InvalidConfigurationException;
 import org.codehaus.plexus.security.rbac.Resource;
 import org.codehaus.plexus.security.ui.web.interceptor.SecureAction;
 import org.codehaus.plexus.security.ui.web.interceptor.SecureActionBundle;
@@ -64,6 +66,11 @@
      */
     private CompanyPomHandler companyPomHandler;
 
+    /**
+     * @plexus.requirement
+     */
+    private MavenBuilderHelper helper;
+
     public String execute()
         throws IOException, ConfigurationStoreException, InvalidConfigurationException, ConfigurationChangeException
     {
@@ -82,7 +89,8 @@
     {
         configuration = configurationStore.getConfigurationFromStore();
 
-        companyModel = companyPomHandler.getCompanyPomModel( configuration.getCompanyPom()
);
+        companyModel =
+            companyPomHandler.getCompanyPomModel( configuration.getCompanyPom(), helper.getLocalRepository()
);
     }
 
     public SecureActionBundle getSecureActionBundle()

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/EditPomAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/EditPomAction.java?view=diff&rev=481456&r1=481455&r2=481456
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/EditPomAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/admin/EditPomAction.java
Fri Dec  1 16:26:32 2006
@@ -22,16 +22,18 @@
 import com.opensymphony.xwork.ModelDriven;
 import org.apache.maven.artifact.installer.ArtifactInstallationException;
 import org.apache.maven.artifact.metadata.ArtifactMetadataRetrievalException;
-import org.apache.maven.continuum.configuration.CompanyPom;
-import org.apache.maven.continuum.configuration.Configuration;
-import org.apache.maven.continuum.configuration.ConfigurationChangeException;
-import org.apache.maven.continuum.configuration.ConfigurationStore;
-import org.apache.maven.continuum.configuration.ConfigurationStoreException;
-import org.apache.maven.continuum.configuration.InvalidConfigurationException;
 import org.apache.maven.continuum.security.ContinuumRoleConstants;
 import org.apache.maven.continuum.web.action.ContinuumActionSupport;
+import org.apache.maven.continuum.execution.maven.m2.MavenBuilderHelper;
 import org.apache.maven.model.Model;
 import org.apache.maven.project.ProjectBuildingException;
+import org.apache.maven.shared.app.configuration.InvalidConfigurationException;
+import org.apache.maven.shared.app.configuration.Configuration;
+import org.apache.maven.shared.app.configuration.ConfigurationStoreException;
+import org.apache.maven.shared.app.configuration.ConfigurationChangeException;
+import org.apache.maven.shared.app.configuration.ConfigurationStore;
+import org.apache.maven.shared.app.configuration.CompanyPom;
+import org.apache.maven.shared.app.company.CompanyPomHandler;
 import org.codehaus.plexus.security.rbac.Resource;
 import org.codehaus.plexus.security.ui.web.interceptor.SecureAction;
 import org.codehaus.plexus.security.ui.web.interceptor.SecureActionBundle;
@@ -66,6 +68,9 @@
 
     private Model companyModel;
 
+    /** @plexus.requirement */
+    private MavenBuilderHelper helper;
+
     public String execute()
         throws IOException, ConfigurationStoreException, InvalidConfigurationException, ConfigurationChangeException,
         ArtifactInstallationException
@@ -77,7 +82,7 @@
             companyModel.getProperties().put( "organization.logo", logo[0] );
         }
 
-        companyPomHandler.save( companyModel );
+        companyPomHandler.save( companyModel, helper.getLocalRepository() );
 
         return SUCCESS;
     }
@@ -93,7 +98,7 @@
         configuration = configurationStore.getConfigurationFromStore();
 
         CompanyPom companyPom = configuration.getCompanyPom();
-        companyModel = companyPomHandler.getCompanyPomModel( companyPom );
+        companyModel = companyPomHandler.getCompanyPomModel( companyPom, helper.getLocalRepository()
);
 
         if ( companyModel == null )
         {

Modified: maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/component/CompanyInfoAction.java
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/component/CompanyInfoAction.java?view=diff&rev=481456&r1=481455&r2=481456
==============================================================================
--- maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/component/CompanyInfoAction.java
(original)
+++ maven/continuum/trunk/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/component/CompanyInfoAction.java
Fri Dec  1 16:26:32 2006
@@ -1,10 +1,5 @@
 package org.apache.maven.continuum.web.action.component;
 
-import com.opensymphony.xwork.ActionSupport;
-import org.apache.maven.continuum.configuration.ConfigurationStore;
-import org.apache.maven.continuum.web.action.admin.CompanyPomHandler;
-import org.apache.maven.model.Model;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -24,6 +19,12 @@
  * under the License.
  */
 
+import com.opensymphony.xwork.ActionSupport;
+import org.apache.maven.continuum.execution.maven.m2.MavenBuilderHelper;
+import org.apache.maven.model.Model;
+import org.apache.maven.shared.app.company.CompanyPomHandler;
+import org.apache.maven.shared.app.configuration.ConfigurationStore;
+
 /**
  * Stores the company information for displaying on the page.
  *
@@ -48,10 +49,16 @@
      */
     private ConfigurationStore configurationStore;
 
+    /**
+     * @plexus.requirement
+     */
+    private MavenBuilderHelper helper;
+
     public String execute()
         throws Exception
     {
-        Model model = handler.getCompanyPomModel( configurationStore.getConfigurationFromStore().getCompanyPom()
);
+        Model model = handler.getCompanyPomModel( configurationStore.getConfigurationFromStore().getCompanyPom(),
+                                                  helper.getLocalRepository() );
 
         if ( model != null )
         {

Modified: maven/continuum/trunk/pom.xml
URL: http://svn.apache.org/viewvc/maven/continuum/trunk/pom.xml?view=diff&rev=481456&r1=481455&r2=481456
==============================================================================
--- maven/continuum/trunk/pom.xml (original)
+++ maven/continuum/trunk/pom.xml Fri Dec  1 16:26:32 2006
@@ -331,6 +331,16 @@
         <type>war</type>
       </dependency>
       <dependency>
+        <groupId>org.apache.maven.shared</groupId>
+        <artifactId>maven-app-configuration-model</artifactId>
+        <version>1.0-SNAPSHOT</version>
+      </dependency>
+      <dependency>
+        <groupId>org.apache.maven.shared</groupId>
+        <artifactId>maven-app-configuration-web</artifactId>
+        <version>1.0-SNAPSHOT</version>
+      </dependency>
+      <dependency>
         <groupId>jpox</groupId>
         <artifactId>jpox</artifactId>
         <version>1.1.1</version>



Mime
View raw message