You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by br...@apache.org on 2006/08/09 10:20:03 UTC

svn commit: r429989 - in /maven/repository-manager/trunk: design/white-site/src/site/xdoc/admin/ maven-repository-configuration/ maven-repository-configuration/src/main/mdo/ maven-repository-configuration/src/main/resources/ maven-repository-configurat...

Author: brett
Date: Wed Aug  9 01:20:02 2006
New Revision: 429989

URL: http://svn.apache.org/viewvc?rev=429989&view=rev
Log:
[MRM-138] add configuration of synced repositories

Added:
    maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/
    maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/
    maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/
    maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/
    maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/
    maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/
    maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/SyncedRepositoryConfiguration-conversion.properties   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction.java   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/DeleteSyncedRepositoryAction.java   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-addSelectedSyncedRepository-validation.xml   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-validation.xml   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addSyncedRepository.jsp   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/deleteSyncedRepository.jsp   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editSyncedRepository.jsp   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/selectSyncedRepository.jsp   (with props)
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/syncedRepositories.jsp   (with props)
Modified:
    maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/add-sync-repository.xml
    maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-cvs-sync-repository.xml
    maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-file-sync-repository.xml
    maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-rsync-sync-repository.xml
    maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-svn-sync-repository.xml
    maven/repository-manager/trunk/maven-repository-configuration/pom.xml
    maven/repository-manager/trunk/maven-repository-configuration/src/main/mdo/configuration.mdo
    maven/repository-manager/trunk/maven-repository-webapp/pom.xml
    maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/AbstractConfigureRepositoryAction.java
    maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureProxiedRepositoryAction-validation.xml
    maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/xwork.xml
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addProxiedRepository.jsp
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editProxiedRepository.jsp
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/proxiedRepositories.jsp
    maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/web.xml

Modified: maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/add-sync-repository.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/add-sync-repository.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/add-sync-repository.xml (original)
+++ maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/add-sync-repository.xml Wed Aug  9 01:20:02 2006
@@ -27,18 +27,6 @@
       <form onsubmit="this.action=this.method.value;" method="POST">
         <table>
           <tr>
-            <th>Identifier</th>
-            <td>
-              <input type="text"/>
-            </td>
-          </tr>
-          <tr>
-            <th>Name</th>
-            <td>
-              <input type="text"/>
-            </td>
-          </tr>
-          <tr>
             <th>Method</th>
             <td>
               <select name="method">
@@ -47,30 +35,6 @@
                 <option value="edit-cvs-sync-repository.html">CVS</option>
                 <option value="edit-file-sync-repository.html">Local File System</option>
               </select>
-            </td>
-          </tr>
-          <tr>
-            <th>Type</th>
-            <td>
-              <select>
-                <option selected="selected">Maven 2.x Repository</option>
-                <option>Maven 1.x Repository</option>
-              </select>
-            </td>
-          </tr>
-          <tr>
-            <th>Synced to</th>
-            <td>
-              <select>
-                <option selected="selected">Central Repository (central)</option>
-                <option>Snapshot Repository (central-snapshots)</option>
-              </select>
-            </td>
-          </tr>
-          <tr>
-            <th>Schedule</th>
-            <td>
-              <input type="text"/>
             </td>
           </tr>
           <tr>

Modified: maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-cvs-sync-repository.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-cvs-sync-repository.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-cvs-sync-repository.xml (original)
+++ maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-cvs-sync-repository.xml Wed Aug  9 01:20:02 2006
@@ -24,11 +24,46 @@
     <div id="contentArea">
       <h2>Add (Edit) Repository</h2>
 
-      <h3>NAME GOES HERE</h3>
       <form action="sync.html">
         <table>
           <tr>
+            <th>Identifier</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Name</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
             <th>CVS Root</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Type</th>
+            <td>
+              <select>
+                <option selected="selected">Maven 2.x Repository</option>
+                <option>Maven 1.x Repository</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Synced to</th>
+            <td>
+              <select>
+                <option selected="selected">Central Repository (central)</option>
+                <option>Snapshot Repository (central-snapshots)</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Schedule</th>
             <td>
               <input type="text"/>
             </td>

Modified: maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-file-sync-repository.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-file-sync-repository.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-file-sync-repository.xml (original)
+++ maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-file-sync-repository.xml Wed Aug  9 01:20:02 2006
@@ -24,11 +24,46 @@
     <div id="contentArea">
       <h2>Add (Edit) Repository</h2>
 
-      <h3>NAME GOES HERE</h3>
       <form action="sync.html">
         <table>
           <tr>
+            <th>Identifier</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Name</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
             <th>Directory</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Type</th>
+            <td>
+              <select>
+                <option selected="selected">Maven 2.x Repository</option>
+                <option>Maven 1.x Repository</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Synced to</th>
+            <td>
+              <select>
+                <option selected="selected">Central Repository (central)</option>
+                <option>Snapshot Repository (central-snapshots)</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Schedule</th>
             <td>
               <input type="text"/>
             </td>

Modified: maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-rsync-sync-repository.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-rsync-sync-repository.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-rsync-sync-repository.xml (original)
+++ maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-rsync-sync-repository.xml Wed Aug  9 01:20:02 2006
@@ -24,10 +24,21 @@
     <div id="contentArea">
       <h2>Add (Edit) Repository</h2>
 
-      <h3>NAME GOES HERE</h3>
       <form action="sync.html">
         <table>
           <tr>
+            <th>Identifier</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Name</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
             <th>Host</th>
             <td>
               <input type="text"/>
@@ -41,6 +52,30 @@
           </tr>
           <tr>
             <th>Username</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Type</th>
+            <td>
+              <select>
+                <option selected="selected">Maven 2.x Repository</option>
+                <option>Maven 1.x Repository</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Synced to</th>
+            <td>
+              <select>
+                <option selected="selected">Central Repository (central)</option>
+                <option>Snapshot Repository (central-snapshots)</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Schedule</th>
             <td>
               <input type="text"/>
             </td>

Modified: maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-svn-sync-repository.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-svn-sync-repository.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-svn-sync-repository.xml (original)
+++ maven/repository-manager/trunk/design/white-site/src/site/xdoc/admin/edit-svn-sync-repository.xml Wed Aug  9 01:20:02 2006
@@ -24,10 +24,27 @@
     <div id="contentArea">
       <h2>Add (Edit) Repository</h2>
 
-      <h3>NAME GOES HERE</h3>
       <form action="sync.html">
         <table>
           <tr>
+            <th>Identifier</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Name</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Host</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
             <th>Subversion URL</th>
             <td>
               <input type="text"/>
@@ -35,6 +52,30 @@
           </tr>
           <tr>
             <th>Username</th>
+            <td>
+              <input type="text"/>
+            </td>
+          </tr>
+          <tr>
+            <th>Type</th>
+            <td>
+              <select>
+                <option selected="selected">Maven 2.x Repository</option>
+                <option>Maven 1.x Repository</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Synced to</th>
+            <td>
+              <select>
+                <option selected="selected">Central Repository (central)</option>
+                <option>Snapshot Repository (central-snapshots)</option>
+              </select>
+            </td>
+          </tr>
+          <tr>
+            <th>Schedule</th>
             <td>
               <input type="text"/>
             </td>

Modified: maven/repository-manager/trunk/maven-repository-configuration/pom.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-configuration/pom.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-configuration/pom.xml (original)
+++ maven/repository-manager/trunk/maven-repository-configuration/pom.xml Wed Aug  9 01:20:02 2006
@@ -24,7 +24,7 @@
       <plugin>
         <groupId>org.codehaus.modello</groupId>
         <artifactId>modello-maven-plugin</artifactId>
-        <version>1.0-alpha-8</version>
+        <version>1.0-alpha-10</version>
         <executions>
           <execution>
             <goals>

Modified: maven/repository-manager/trunk/maven-repository-configuration/src/main/mdo/configuration.mdo
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-configuration/src/main/mdo/configuration.mdo?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-configuration/src/main/mdo/configuration.mdo (original)
+++ maven/repository-manager/trunk/maven-repository-configuration/src/main/mdo/configuration.mdo Wed Aug  9 01:20:02 2006
@@ -349,26 +349,9 @@
     <class>
       <superClass>AbstractRepositoryConfiguration</superClass>
       <name>SyncedRepositoryConfiguration</name>
+      <abstract>true</abstract>
       <version>1.0.0</version>
       <fields>
-        <field>
-          <name>rsyncHost</name>
-          <version>1.0.0</version>
-          <type>String</type>
-          <required>true</required>
-          <description>
-            The host of the remote repository to synchronize.
-          </description>
-        </field>
-        <field>
-          <name>rsyncDirectory</name>
-          <version>1.0.0</version>
-          <type>String</type>
-          <required>true</required>
-          <description>
-            The location of the repository to synchronize on the remote host.
-          </description>
-        </field>
         <!-- TODO: would be much easier to have an association here, as long as it could be specified as a reference -->
         <field>
           <name>managedRepository</name>
@@ -386,62 +369,22 @@
           <description>When to run the sync mechanism. Default is every hour on the hour.</description>
           <defaultValue>0 0 * * * ?</defaultValue>
         </field>
-      </fields>
-    </class>
-    <class>
-      <superClass>SyncedRepositoryConfiguration</superClass>
-      <name>RsyncSyncedRepositoryConfiguration</name>
-      <version>1.0.0</version>
-      <fields>
         <field>
-          <name>rsyncHost</name>
+          <name>method</name>
           <version>1.0.0</version>
           <type>String</type>
-          <required>true</required>
-          <description>
-            The host of the remote repository to synchronize.
-          </description>
+          <description>The type of synchronization to use.</description>
+          <defaultValue>rsync</defaultValue>
         </field>
         <field>
-          <name>rsyncDirectory</name>
+          <name>properties</name>
           <version>1.0.0</version>
-          <type>String</type>
-          <required>true</required>
-          <description>
-            The location of the repository to synchronize on the remote host.
-          </description>
-        </field>
-      </fields>
-    </class>
-    <class>
-      <superClass>SyncedRepositoryConfiguration</superClass>
-      <name>ScmSyncedRepositoryConfiguration</name>
-      <version>1.0.0</version>
-      <fields>
-        <field>
-          <name>scmUrl</name>
-          <version>1.0.0</version>
-          <type>String</type>
-          <required>true</required>
-          <description>
-            The SCM URL of the remote repository to synchronize.
-          </description>
-        </field>
-      </fields>
-    </class>
-    <class>
-      <superClass>SyncedRepositoryConfiguration</superClass>
-      <name>FileSyncedRepositoryConfiguration</name>
-      <version>1.0.0</version>
-      <fields>
-        <field>
-          <name>directory</name>
-          <version>1.0.0</version>
-          <type>String</type>
-          <required>true</required>
-          <description>
-            The location of the repository to synchronize on the filesystem.
-          </description>
+          <type>Properties</type>
+          <description>Configuration for the repository synchronization.</description>
+          <association xml.mapStyle="inline">
+            <type>String</type>
+            <multiplicity>*</multiplicity>
+          </association>
         </field>
       </fields>
     </class>

Added: maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/SyncedRepositoryConfiguration-conversion.properties
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/SyncedRepositoryConfiguration-conversion.properties?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/SyncedRepositoryConfiguration-conversion.properties (added)
+++ maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/SyncedRepositoryConfiguration-conversion.properties Wed Aug  9 01:20:02 2006
@@ -0,0 +1,18 @@
+#
+# Copyright 2005-2006 The Apache Software Foundation.
+#
+# Licensed 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.
+#
+
+Key_properties=java.lang.String
+Element_properties=java.lang.String

Propchange: maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/SyncedRepositoryConfiguration-conversion.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-configuration/src/main/resources/org/apache/maven/repository/configuration/SyncedRepositoryConfiguration-conversion.properties
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: maven/repository-manager/trunk/maven-repository-webapp/pom.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/pom.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/pom.xml (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/pom.xml Wed Aug  9 01:20:02 2006
@@ -107,6 +107,7 @@
         <artifactId>maven-jetty-plugin</artifactId>
         <configuration>
           <scanIntervalSeconds>10</scanIntervalSeconds>
+          <contextPath>/</contextPath>
           <connectors>
             <connector implementation="org.mortbay.jetty.nio.SelectChannelConnector">
               <port>9000</port>

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/AbstractConfigureRepositoryAction.java
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/AbstractConfigureRepositoryAction.java?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/AbstractConfigureRepositoryAction.java (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/AbstractConfigureRepositoryAction.java Wed Aug  9 01:20:02 2006
@@ -16,7 +16,6 @@
  * limitations under the License.
  */
 
-import com.opensymphony.webwork.interceptor.ParameterAware;
 import com.opensymphony.xwork.ActionSupport;
 import com.opensymphony.xwork.ModelDriven;
 import com.opensymphony.xwork.Preparable;
@@ -28,7 +27,6 @@
 import org.apache.maven.repository.configuration.InvalidConfigurationException;
 
 import java.io.IOException;
-import java.util.Map;
 
 /**
  * Base action for repository configuration actions.
@@ -37,7 +35,7 @@
  */
 public abstract class AbstractConfigureRepositoryAction
     extends ActionSupport
-    implements ModelDriven, Preparable, ParameterAware
+    implements ModelDriven, Preparable
 {
     /**
      * @plexus.requirement
@@ -113,14 +111,6 @@
 
     public Object getModel()
     {
-        if ( repository == null )
-        {
-            repository = getRepository( repoId );
-        }
-        if ( repository == null )
-        {
-            repository = createRepository();
-        }
         return repository;
     }
 
@@ -131,8 +121,14 @@
     {
         configuration = configurationStore.getConfigurationFromStore();
 
-        // initialises the repository if it is empty
-        getModel();
+        if ( repository == null )
+        {
+            repository = getRepository( repoId );
+        }
+        if ( repository == null )
+        {
+            repository = createRepository();
+        }
     }
 
     public String getRepoId()
@@ -143,15 +139,6 @@
     public void setRepoId( String repoId )
     {
         this.repoId = repoId;
-    }
-
-    public void setParameters( Map map )
-    {
-        if ( map.containsKey( "repoId" ) )
-        {
-            String[] param = (String[]) map.get( "repoId" );
-            repoId = param[0];
-        }
     }
 
     protected AbstractRepositoryConfiguration getRepository()

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction.java
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction.java?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction.java (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction.java Wed Aug  9 01:20:02 2006
@@ -0,0 +1,54 @@
+package org.apache.maven.repository.manager.web.action.admin;
+
+/*
+ * Copyright 2005-2006 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import org.apache.maven.repository.configuration.AbstractRepositoryConfiguration;
+import org.apache.maven.repository.configuration.SyncedRepositoryConfiguration;
+
+import java.io.IOException;
+
+/**
+ * Configures the application repositories.
+ *
+ * @plexus.component role="com.opensymphony.xwork.Action" role-hint="configureSyncedRepositoryAction"
+ */
+public class ConfigureSyncedRepositoryAction
+    extends AbstractConfigureRepositoryAction
+{
+    protected void removeRepository( AbstractRepositoryConfiguration existingRepository )
+    {
+        configuration.removeSyncedRepository( (SyncedRepositoryConfiguration) existingRepository );
+    }
+
+    protected AbstractRepositoryConfiguration getRepository( String id )
+    {
+        return configuration.getSyncedRepositoryById( id );
+    }
+
+    protected void addRepository()
+        throws IOException
+    {
+        SyncedRepositoryConfiguration repository = (SyncedRepositoryConfiguration) getRepository();
+
+        configuration.addSyncedRepository( repository );
+    }
+
+    protected AbstractRepositoryConfiguration createRepository()
+    {
+        return new SyncedRepositoryConfiguration();
+    }
+}

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/DeleteSyncedRepositoryAction.java
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/DeleteSyncedRepositoryAction.java?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/DeleteSyncedRepositoryAction.java (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/DeleteSyncedRepositoryAction.java Wed Aug  9 01:20:02 2006
@@ -0,0 +1,48 @@
+package org.apache.maven.repository.manager.web.action.admin;
+
+/*
+ * Copyright 2005-2006 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
+
+import org.apache.maven.repository.configuration.AbstractRepositoryConfiguration;
+import org.apache.maven.repository.configuration.SyncedRepositoryConfiguration;
+import org.apache.maven.repository.configuration.Configuration;
+
+import java.io.IOException;
+
+/**
+ * Configures the application repositories.
+ *
+ * @plexus.component role="com.opensymphony.xwork.Action" role-hint="deleteSyncedRepositoryAction"
+ */
+public class DeleteSyncedRepositoryAction
+    extends AbstractDeleteRepositoryAction
+{
+    protected AbstractRepositoryConfiguration getRepository( Configuration configuration )
+    {
+        return configuration.getSyncedRepositoryById( repoId );
+    }
+
+    protected void removeRepository( Configuration configuration, AbstractRepositoryConfiguration existingRepository )
+    {
+        configuration.removeSyncedRepository( (SyncedRepositoryConfiguration) existingRepository );
+    }
+
+    protected void removeContents( AbstractRepositoryConfiguration existingRepository )
+        throws IOException
+    {
+        // TODO!
+    }
+}

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/DeleteSyncedRepositoryAction.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/java/org/apache/maven/repository/manager/web/action/admin/DeleteSyncedRepositoryAction.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureProxiedRepositoryAction-validation.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureProxiedRepositoryAction-validation.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureProxiedRepositoryAction-validation.xml (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureProxiedRepositoryAction-validation.xml Wed Aug  9 01:20:02 2006
@@ -34,6 +34,7 @@
       <message>You must enter the repository URL.</message>
     </field-validator>
   </field>
+  <!-- TODO: validate managed repository -->
   <!-- TODO: validate layout -->
   <!-- TODO: validate policies -->
   <!-- TODO: validate that intervals are integers -->

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-addSelectedSyncedRepository-validation.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-addSelectedSyncedRepository-validation.xml?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-addSelectedSyncedRepository-validation.xml (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-addSelectedSyncedRepository-validation.xml Wed Aug  9 01:20:02 2006
@@ -0,0 +1,34 @@
+<!--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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 validators PUBLIC "-//OpenSymphony Group//XWork Validator 1.0.2//EN"
+    "http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd">
+
+<validators>
+  <field name="id">
+    <field-validator type="requiredstring">
+      <message>You must enter the repository identifier.</message>
+    </field-validator>
+  </field>
+  <field name="name">
+    <field-validator type="requiredstring">
+      <message>You must enter the repository name.</message>
+    </field-validator>
+  </field>
+  <!-- TODO: validate managed repository -->
+  <!-- TODO: validate layout -->
+  <!-- TODO: validate sync settings, depending on what method -->
+</validators>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-addSelectedSyncedRepository-validation.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-addSelectedSyncedRepository-validation.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-validation.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-validation.xml?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-validation.xml (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-validation.xml Wed Aug  9 01:20:02 2006
@@ -0,0 +1,27 @@
+<!--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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 validators PUBLIC "-//OpenSymphony Group//XWork Validator 1.0.2//EN"
+    "http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd">
+
+<validators>
+  <!-- TODO: constrain more -->
+  <field name="method">
+    <field-validator type="requiredstring">
+      <message>You must enter the synchronization method.</message>
+    </field-validator>
+  </field>
+</validators>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-validation.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/org/apache/maven/repository/manager/web/action/admin/ConfigureSyncedRepositoryAction-validation.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/xwork.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/xwork.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/xwork.xml (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/resources/xwork.xml Wed Aug  9 01:20:02 2006
@@ -30,6 +30,10 @@
         <interceptor-ref name="defaultStack"/>
         <interceptor-ref name="configuration"/>
       </interceptor-stack>
+      <interceptor-stack name="configuredPrepareParamsStack">
+        <interceptor-ref name="paramsPrepareParamsStack"/>
+        <interceptor-ref name="configuration"/>
+      </interceptor-stack>
     </interceptors>
 
     <!-- Default interceptor stack. -->
@@ -135,6 +139,7 @@
     <action name="editRepository" class="configureRepositoryAction" method="edit">
       <result name="input">/WEB-INF/jsp/admin/editRepository.jsp</result>
       <result type="redirect-action">index</result>
+      <interceptor-ref name="configuredPrepareParamsStack"/>
     </action>
 
     <action name="deleteRepository" class="deleteRepositoryAction">
@@ -154,11 +159,40 @@
     <action name="editProxiedRepository" class="configureProxiedRepositoryAction" method="edit">
       <result name="input">/WEB-INF/jsp/admin/editProxiedRepository.jsp</result>
       <result type="redirect-action">proxiedRepositories</result>
+      <interceptor-ref name="configuredPrepareParamsStack"/>
     </action>
 
     <action name="deleteProxiedRepository" class="deleteProxiedRepositoryAction">
       <result name="input">/WEB-INF/jsp/admin/deleteProxiedRepository.jsp</result>
       <result type="redirect-action">proxiedRepositories</result>
+    </action>
+
+    <action name="syncedRepositories" class="configureAction" method="input">
+      <result name="input">/WEB-INF/jsp/admin/syncedRepositories.jsp</result>
+    </action>
+
+    <action name="addSyncedRepository" class="configureSyncedRepositoryAction">
+      <result name="input">/WEB-INF/jsp/admin/selectSyncedRepository.jsp</result>
+      <result type="chain">
+        <param name="actionName">addSelectedSyncedRepository</param>
+        <param name="method">input</param>
+      </result>
+    </action>
+
+    <action name="addSelectedSyncedRepository" class="configureSyncedRepositoryAction" method="add">
+      <result name="input">/WEB-INF/jsp/admin/addSyncedRepository.jsp</result>
+      <result type="redirect-action">syncedRepositories</result>
+    </action>
+
+    <action name="editSyncedRepository" class="configureSyncedRepositoryAction" method="edit">
+      <result name="input">/WEB-INF/jsp/admin/editSyncedRepository.jsp</result>
+      <result type="redirect-action">syncedRepositories</result>
+      <interceptor-ref name="configuredPrepareParamsStack"/>
+    </action>
+
+    <action name="deleteSyncedRepository" class="deleteSyncedRepositoryAction">
+      <result name="input">/WEB-INF/jsp/admin/deleteSyncedRepository.jsp</result>
+      <result type="redirect-action">syncedRepositories</result>
     </action>
 
     <action name="configure" class="configureAction" method="input">

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addProxiedRepository.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addProxiedRepository.jsp?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addProxiedRepository.jsp (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addProxiedRepository.jsp Wed Aug  9 01:20:02 2006
@@ -33,25 +33,7 @@
   <ww:actionmessage />
   <ww:form method="post" action="addProxiedRepository" namespace="/admin" validate="true">
     <ww:textfield name="id" label="Identifier" size="10" />
-    <ww:textfield name="name" label="Name" size="50" />
-    <ww:textfield name="url" label="URL" size="50" />
-    <ww:select list="#@java.util.LinkedHashMap@{'default' : 'Maven 2.x Repository', 'legacy' : 'Maven 1.x Repository'}"
-               name="layout" label="Type" />
-    <ww:select name="snapshotsPolicy" label="Snapshots" list="#@java.util.LinkedHashMap@{
-        'disabled' : 'Disabled',
-        'daily' : 'Enabled, updated daily',
-        'hourly' : 'Enabled, updated hourly',
-        'never' : 'Enabled, never updated',
-        'interval' : 'Enabled, updated on given interval'}" />
-    <ww:textfield label="Snapshot update interval" name="snapshotsInterval" size="4" />
-    <ww:select name="releasesPolicy" label="Releases" list="#@java.util.LinkedHashMap@{
-        'disabled' : 'Disabled',
-        'daily' : 'Enabled, updated daily',
-        'hourly' : 'Enabled, updated hourly',
-        'never' : 'Enabled, never updated',
-        'interval' : 'Enabled, updated on given interval'}" />
-    <ww:textfield label="Release update interval" name="releasesInterval" size="4" />
-    <ww:select list="configuration.repositoriesMap" name="managedRepository" label="Proxied through"/>
+    <%@ include file="/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf" %>
 
     <ww:submit value="Add Repository" />
   </ww:form>

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addSyncedRepository.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addSyncedRepository.jsp?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addSyncedRepository.jsp (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addSyncedRepository.jsp Wed Aug  9 01:20:02 2006
@@ -0,0 +1,44 @@
+<%--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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.
+  --%>
+
+<%@ taglib prefix="ww" uri="/webwork" %>
+<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
+
+<html>
+<head>
+  <title>Configuration</title>
+  <ww:head />
+</head>
+
+<body>
+
+<h1>Configuration</h1>
+
+<div id="contentArea">
+
+  <h2>Add Synced Repository</h2>
+
+  <ww:actionmessage />
+  <ww:form method="post" action="addSelectedSyncedRepository" namespace="/admin" validate="true">
+    <ww:textfield name="id" label="Identifier" size="10" />
+    <%@ include file="/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf" %>
+
+    <ww:submit value="Add Repository" />
+  </ww:form>
+</div>
+
+</body>
+</html>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/addSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/deleteSyncedRepository.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/deleteSyncedRepository.jsp?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/deleteSyncedRepository.jsp (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/deleteSyncedRepository.jsp Wed Aug  9 01:20:02 2006
@@ -0,0 +1,48 @@
+<%--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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.
+  --%>
+
+<%@ taglib prefix="ww" uri="/webwork" %>
+
+<html>
+<head>
+  <title>Configuration</title>
+  <ww:head />
+</head>
+
+<body>
+
+<h1>Configuration</h1>
+
+<div id="contentArea">
+
+  <h2>Delete Synced Repository</h2>
+
+  <blockquote>
+    <strong><span class="statusFailed">WARNING:</span> This operation can not be undone.</strong>
+  </blockquote>
+
+  <ww:form method="post" action="deleteSyncedRepository" namespace="/admin" validate="true">
+    <ww:hidden name="repoId" />
+    <ww:radio list="#@java.util.LinkedHashMap@{
+    'delete-contents' : 'Remove the repository and delete its contents from managed repositories',
+    'delete-entry' : 'Remove the repository from the available list, but leave the contents in the managed repositories',
+    'unmodified' : 'Leave the repository unmodified'}" name="operation" theme="repository-manager" />
+    <ww:submit value="Go" />
+  </ww:form>
+</div>
+
+</body>
+</html>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/deleteSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/deleteSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editProxiedRepository.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editProxiedRepository.jsp?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editProxiedRepository.jsp (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editProxiedRepository.jsp Wed Aug  9 01:20:02 2006
@@ -33,26 +33,7 @@
   <ww:actionmessage />
   <ww:form method="post" action="editProxiedRepository" namespace="/admin" validate="true">
     <ww:hidden name="id" />
-    <!-- TODO! share with add -->
-    <ww:textfield name="name" label="Name" size="50" />
-    <ww:textfield name="url" label="URL" size="50" />
-    <ww:select list="#@java.util.LinkedHashMap@{'default' : 'Maven 2.x Repository', 'legacy' : 'Maven 1.x Repository'}"
-               name="layout" label="Type" />
-    <ww:select name="snapshotsPolicy" label="Snapshots" list="#@java.util.LinkedHashMap@{
-        'disabled' : 'Disabled',
-        'daily' : 'Enabled, updated daily',
-        'hourly' : 'Enabled, updated hourly',
-        'never' : 'Enabled, never updated',
-        'interval' : 'Enabled, updated on given interval'}" />
-    <ww:textfield label="Snapshot update interval" name="snapshotsInterval" size="4" />
-    <ww:select name="releasesPolicy" label="Releases" list="#@java.util.LinkedHashMap@{
-        'disabled' : 'Disabled',
-        'daily' : 'Enabled, updated daily',
-        'hourly' : 'Enabled, updated hourly',
-        'never' : 'Enabled, never updated',
-        'interval' : 'Enabled, updated on given interval'}" />
-    <ww:textfield label="Release update interval" name="releasesInterval" size="4" />
-    <ww:select list="configuration.repositoriesMap" name="managedRepository" label="Proxied through"/>
+    <%@ include file="/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf" %>
     <ww:submit value="Change Repository" />
   </ww:form>
 </div>

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editSyncedRepository.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editSyncedRepository.jsp?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editSyncedRepository.jsp (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editSyncedRepository.jsp Wed Aug  9 01:20:02 2006
@@ -0,0 +1,44 @@
+<%--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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.
+  --%>
+
+<%@ taglib prefix="ww" uri="/webwork" %>
+<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
+
+<html>
+<head>
+  <title>Configuration</title>
+  <ww:head />
+</head>
+
+<body>
+
+<h1>Configuration</h1>
+
+<div id="contentArea">
+
+  <h2>Edit Synced Repository</h2>
+
+  <ww:actionmessage />
+  <ww:form method="post" action="editSyncedRepository" namespace="/admin" validate="true">
+    <ww:hidden name="id" />
+    <%@ include file="/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf" %>
+
+    <ww:submit value="Update Repository" />
+  </ww:form>
+</div>
+
+</body>
+</html>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/editSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf Wed Aug  9 01:20:02 2006
@@ -0,0 +1,35 @@
+<%--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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.
+  --%>
+
+<ww:textfield name="name" label="Name" size="50" />
+<ww:textfield name="url" label="URL" size="50" />
+<ww:select list="#@java.util.LinkedHashMap@{'default' : 'Maven 2.x Repository', 'legacy' : 'Maven 1.x Repository'}"
+           name="layout" label="Type" />
+<ww:select name="snapshotsPolicy" label="Snapshots" list="#@java.util.LinkedHashMap@{
+        'disabled' : 'Disabled',
+        'daily' : 'Enabled, updated daily',
+        'hourly' : 'Enabled, updated hourly',
+        'never' : 'Enabled, never updated',
+        'interval' : 'Enabled, updated on given interval'}" />
+<ww:textfield label="Snapshot update interval" name="snapshotsInterval" size="4" />
+<ww:select name="releasesPolicy" label="Releases" list="#@java.util.LinkedHashMap@{
+        'disabled' : 'Disabled',
+        'daily' : 'Enabled, updated daily',
+        'hourly' : 'Enabled, updated hourly',
+        'never' : 'Enabled, never updated',
+        'interval' : 'Enabled, updated on given interval'}" />
+<ww:textfield label="Release update interval" name="releasesInterval" size="4" />
+<ww:select list="configuration.repositoriesMap" name="managedRepository" label="Proxied through"/>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/proxiedRepositoryForm.jspf
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf Wed Aug  9 01:20:02 2006
@@ -0,0 +1,27 @@
+<ww:hidden name="method" />
+<ww:textfield name="name" label="Name" size="50" />
+<ww:select list="#@java.util.LinkedHashMap@{'default' : 'Maven 2.x Repository', 'legacy' : 'Maven 1.x Repository'}"
+           name="layout" label="Type" />
+<ww:select list="configuration.repositoriesMap" name="managedRepository" label="Synced to" />
+<ww:textfield name="cronExpression" label="Schedule" />
+
+<ww:set name="method" value="method" />
+<c:choose>
+  <c:when test="${method == 'cvs'}">
+    <ww:textfield name="properties['cvsRoot']" label="CVS Root" size="100" />
+  </c:when>
+  <c:when test="${method == 'svn'}">
+    <ww:textfield name="properties['svnUrl']" label="Subversion URL" size="100" />
+    <ww:textfield name="properties['username']" label="Subversion Username" size="30" />
+  </c:when>
+  <c:when test="${method == 'rsync'}">
+    <ww:textfield name="properties['rsyncHost']" label="Rsync Host" />
+    <ww:textfield name="properties['rsyncDirectory']" label="Rsync Directory" size="100" />
+    <ww:select name="properties['rsyncMethod']" label="Rsync Method"
+               list="#@java.util.LinkedHashMap@{'rsync' : 'Anonymous', 'ssh' : 'SSH'}" />
+    <ww:textfield name="properties['username']" label="Rsync Username" size="30" />
+  </c:when>
+  <c:when test="${method == 'file'}">
+    <ww:textfield name="properties['directory']" label="Directory" size="100" />
+  </c:when>
+</c:choose>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/include/syncedRepositoryForm.jspf
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/index.jsp Wed Aug  9 01:20:02 2006
@@ -62,7 +62,7 @@
   <c:forEach items="${repositories}" var="repository" varStatus="i">
     <div>
       <div style="float: right">
-          <%-- TODO! replace with icons --%>
+          <%-- TODO replace with icons --%>
         <a href="<ww:url action="editRepository" method="input"><ww:param name="repoId" value="%{'${repository.id}'}" /></ww:url>">Edit
           Repository</a> | <a
           href="<ww:url action="deleteRepository" method="input"><ww:param name="repoId" value="%{'${repository.id}'}" /></ww:url>">Delete
@@ -73,7 +73,6 @@
         <tr>
           <th>Identifier</th>
           <td>
-              <%-- TODO! must be unique among managed repos --%>
             <code>${repository.id}</code>
           </td>
         </tr>

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/proxiedRepositories.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/proxiedRepositories.jsp?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/proxiedRepositories.jsp (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/proxiedRepositories.jsp Wed Aug  9 01:20:02 2006
@@ -37,7 +37,7 @@
   <c:forEach items="${proxiedRepositories}" var="repository" varStatus="i">
     <div>
       <div style="float: right">
-          <%-- TODO! replace with icons --%>
+          <%-- TODO replace with icons --%>
         <a href="<ww:url action="editProxiedRepository" method="input"><ww:param name="repoId" value="%{'${repository.id}'}" /></ww:url>">Edit
           Repository</a> | <a
           href="<ww:url action="deleteProxiedRepository" method="input"><ww:param name="repoId" value="%{'${repository.id}'}" /></ww:url>">Delete
@@ -48,7 +48,6 @@
         <tr>
           <th>Identifier</th>
           <td>
-              <%-- TODO! must be unique among managed repos --%>
             <code>${repository.id}</code>
           </td>
         </tr>

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/selectSyncedRepository.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/selectSyncedRepository.jsp?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/selectSyncedRepository.jsp (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/selectSyncedRepository.jsp Wed Aug  9 01:20:02 2006
@@ -0,0 +1,46 @@
+<%--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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.
+  --%>
+
+<%@ taglib prefix="ww" uri="/webwork" %>
+
+<html>
+<head>
+  <title>Configuration</title>
+  <ww:head />
+</head>
+
+<body>
+
+<h1>Configuration</h1>
+
+<div id="contentArea">
+
+  <h2>Add Synced Repository</h2>
+
+  <ww:actionmessage />
+  <ww:form method="post" action="addSyncedRepository" namespace="/admin" validate="true">
+    <ww:select list="#@java.util.LinkedHashMap@{
+      'rsync' : 'Rsync', 
+      'svn' : 'Subversion',
+      'cvs' : 'CVS',
+      'file': 'Local File System'}" name="method" label="Method" />
+
+    <ww:submit value="Continue" />
+  </ww:form>
+</div>
+
+</body>
+</html>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/selectSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/selectSyncedRepository.jsp
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/syncedRepositories.jsp
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/syncedRepositories.jsp?rev=429989&view=auto
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/syncedRepositories.jsp (added)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/syncedRepositories.jsp Wed Aug  9 01:20:02 2006
@@ -0,0 +1,145 @@
+<%--
+  ~ Copyright 2005-2006 The Apache Software Foundation.
+  ~
+  ~ Licensed 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.
+  --%>
+
+<%@ taglib prefix="ww" uri="/webwork" %>
+<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
+
+<html>
+<head>
+  <title>Administration</title>
+  <ww:head />
+</head>
+
+<body>
+
+<h1>Administration</h1>
+
+<div id="contentArea">
+  <h2>Synced Repositories</h2>
+
+  <ww:set name="syncedRepositories" value="syncedRepositories" />
+  <c:if test="${empty(syncedRepositories)}">
+    <strong>There are no synced repositories configured yet.</strong>
+  </c:if>
+  <c:forEach items="${syncedRepositories}" var="repository" varStatus="i">
+    <div>
+      <div style="float: right">
+          <%-- TODO replace with icons --%>
+        <a href="<ww:url action="editSyncedRepository" method="input"><ww:param name="repoId" value="%{'${repository.id}'}" /></ww:url>">Edit
+          Repository</a> | <a
+          href="<ww:url action="deleteSyncedRepository" method="input"><ww:param name="repoId" value="%{'${repository.id}'}" /></ww:url>">Delete
+        Repository</a>
+      </div>
+      <h3>${repository.name}</h3>
+      <table>
+        <tr>
+          <th>Identifier</th>
+          <td>
+            <code>${repository.id}</code>
+          </td>
+        </tr>
+        <tr>
+          <th>Method</th>
+          <td>${repository.method}</td>
+        </tr>
+        <c:choose>
+          <c:when test="${repository.method == 'cvs'}">
+            <tr>
+              <th>CVS Root</th>
+              <td>${repository.properties['cvsRoot']}</td>
+            </tr>
+          </c:when>
+          <c:when test="${repository.method == 'svn'}">
+            <tr>
+              <th>Subversion URL</th>
+              <td>${repository.properties['svnUrl']}</td>
+            </tr>
+            <tr>
+              <th>Subversion Username</th>
+              <td>${repository.properties['username']}</td>
+            </tr>
+          </c:when>
+          <c:when test="${repository.method == 'rsync'}">
+            <tr>
+              <th>Rsync Host</th>
+              <td>${repository.properties['rsyncHost']}</td>
+            </tr>
+            <tr>
+              <th>Rsync Directory</th>
+              <td>${repository.properties['rsyncDirectory']}</td>
+            </tr>
+            <tr>
+              <th>Rsync Method</th>
+              <td>
+                <c:choose>
+                  <c:when test="${repository.properties['rsyncMethod'] == 'rsync'}">
+                    Anonymous
+                  </c:when>
+                  <c:when test="${repository.properties['rsyncMethod'] == 'ssh'}">
+                    SSH
+                  </c:when>
+                </c:choose>
+              </td>
+            </tr>
+            <tr>
+              <th>Username</th>
+              <td>${repository.properties['username']}</td>
+            </tr>
+          </c:when>
+          <c:when test="${repository.method == 'file'}">
+            <tr>
+              <th>Directory</th>
+              <td>${repository.properties['directory']}</td>
+            </tr>
+          </c:when>
+        </c:choose>
+        <tr>
+          <th>Type</th>
+          <!-- TODO: can probably just use layout appended to a key prefix in i18n to simplify this -->
+          <td>
+            <c:choose>
+              <c:when test="${repository.layout == 'default'}">
+                Maven 2.x Repository
+              </c:when>
+              <c:otherwise>
+                Maven 1.x Repository
+              </c:otherwise>
+            </c:choose>
+          </td>
+        </tr>
+        <tr>
+          <th>Synced to</th>
+          <td>
+            <!-- TODO: this is the hard way! would be nice if there was a ref in the model so it was directly linked -->
+            ${repositoriesMap[repository.managedRepository].name}
+            (<code>${repositoriesMap[repository.managedRepository].id}</code>)
+          </td>
+        </tr>
+        <tr>
+          <th>Schedule</th>
+          <td>${repository.cronExpression}</td>
+        </tr>
+      </table>
+    </div>
+  </c:forEach>
+
+  <p>
+    <a href="<ww:url action="addSyncedRepository" method="input" />">Add Repository</a>
+  </p>
+</div>
+
+</body>
+</html>
\ No newline at end of file

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/syncedRepositories.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/jsp/admin/syncedRepositories.jsp
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/web.xml?rev=429989&r1=429988&r2=429989&view=diff
==============================================================================
--- maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/web.xml (original)
+++ maven/repository-manager/trunk/maven-repository-webapp/src/main/webapp/WEB-INF/web.xml Wed Aug  9 01:20:02 2006
@@ -20,13 +20,6 @@
 
   <display-name>Maven Repository Manager</display-name>
 
-  <!-- TODO: remove if we use the new xwork integration
-    <filter>
-      <filter-name>plexus</filter-name>
-      <filter-class>org.codehaus.plexus.xwork.PlexusFilter</filter-class>
-    </filter>
-  -->
-
   <filter>
     <filter-name>webwork-cleanup</filter-name>
     <filter-class>com.opensymphony.webwork.dispatcher.ActionContextCleanUp</filter-class>
@@ -41,14 +34,6 @@
     <filter-name>webwork</filter-name>
     <filter-class>com.opensymphony.webwork.dispatcher.FilterDispatcher</filter-class>
   </filter>
-
-  <!-- this must be before the webwork filter -->
-  <!-- TODO: remove if we use the new xwork integration
-  <filter-mapping>
-    <filter-name>plexus</filter-name>
-    <url-pattern>/*</url-pattern>
-  </filter-mapping>
-  -->
 
   <!-- this must be before the sitemesh filter -->
   <filter-mapping>