continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r685326 - in /continuum/trunk: ./ continuum-commons/src/main/java/org/apache/maven/continuum/utils/ continuum-commons/src/test/resources/ continuum-core/ continuum-core/src/main/java/org/apache/maven/continuum/
Date Tue, 12 Aug 2008 21:32:17 GMT
Author: olamy
Date: Tue Aug 12 14:32:16 2008
New Revision: 685326

URL: http://svn.apache.org/viewvc?rev=685326&view=rev
Log:
[CONTINUUM-1489] replace use of MungedHttpsURL with commons-httpclient 
start with removing use of formica validator


Modified:
    continuum/trunk/continuum-commons/src/main/java/org/apache/maven/continuum/utils/ContinuumUrlValidator.java
    continuum/trunk/continuum-commons/src/test/resources/log4j.xml
    continuum/trunk/continuum-core/pom.xml
    continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
    continuum/trunk/pom.xml

Modified: continuum/trunk/continuum-commons/src/main/java/org/apache/maven/continuum/utils/ContinuumUrlValidator.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-commons/src/main/java/org/apache/maven/continuum/utils/ContinuumUrlValidator.java?rev=685326&r1=685325&r2=685326&view=diff
==============================================================================
--- continuum/trunk/continuum-commons/src/main/java/org/apache/maven/continuum/utils/ContinuumUrlValidator.java
(original)
+++ continuum/trunk/continuum-commons/src/main/java/org/apache/maven/continuum/utils/ContinuumUrlValidator.java
Tue Aug 12 14:32:16 2008
@@ -35,7 +35,7 @@
  * @author <a href="mailto:olamy@apache.org">olamy</a>
  * @since 27 mars 2008
  * @version $Id$
- * @plexus.component
+ * @plexus.component role="org.apache.maven.continuum.utils.ContinuumUrlValidator"
  *   role-hint="continuumUrl"
  */
 public class ContinuumUrlValidator
@@ -78,8 +78,6 @@
      */
     private static final String URL_PATTERN = "/^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?/";
 
-    //                                                                      12          
 3  4          5       6   7        8 9
-
     /**
      * Schema/Protocol (ie. http:, ftp:, file:, etc).
      */

Modified: continuum/trunk/continuum-commons/src/test/resources/log4j.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-commons/src/test/resources/log4j.xml?rev=685326&r1=685325&r2=685326&view=diff
==============================================================================
--- continuum/trunk/continuum-commons/src/test/resources/log4j.xml (original)
+++ continuum/trunk/continuum-commons/src/test/resources/log4j.xml Tue Aug 12 14:32:16 2008
@@ -26,7 +26,7 @@
   </category>
 
   <category name="org.apache.commons.configuration">
-    <priority value="DEBUG"/>
+    <priority value="ERROR"/>
   </category>
 
   <!-- JPOX -->

Modified: continuum/trunk/continuum-core/pom.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-core/pom.xml?rev=685326&r1=685325&r2=685326&view=diff
==============================================================================
--- continuum/trunk/continuum-core/pom.xml (original)
+++ continuum/trunk/continuum-core/pom.xml Tue Aug 12 14:32:16 2008
@@ -119,6 +119,10 @@
       <artifactId>plexus-formica</artifactId>
     </dependency>
     <dependency>
+      <groupId>org.apache.httpcomponents</groupId>
+      <artifactId>httpclient</artifactId>
+    </dependency>    
+    <dependency>
       <groupId>org.codehaus.plexus</groupId>
       <artifactId>plexus-action</artifactId>
       <version>1.0-alpha-6</version>

Modified: continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java?rev=685326&r1=685325&r2=685326&view=diff
==============================================================================
--- continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
(original)
+++ continuum/trunk/continuum-core/src/main/java/org/apache/maven/continuum/DefaultContinuum.java
Tue Aug 12 14:32:16 2008
@@ -64,6 +64,7 @@
 import org.apache.maven.continuum.scm.queue.CheckOutTask;
 import org.apache.maven.continuum.store.ContinuumObjectNotFoundException;
 import org.apache.maven.continuum.store.ContinuumStoreException;
+import org.apache.maven.continuum.utils.ContinuumUrlValidator;
 import org.apache.maven.continuum.utils.ProjectSorter;
 import org.apache.maven.continuum.utils.WorkingDirectoryService;
 import org.codehaus.plexus.PlexusConstants;
@@ -223,9 +224,9 @@
 
 
     /**
-     * @plexus.requirement role-hint="url"
+     * @plexus.requirement role-hint="continuumUrl"
      */
-    private Validator urlValidator;
+    private ContinuumUrlValidator urlValidator;
 
     private boolean stopped = false;
 
@@ -1731,18 +1732,11 @@
     {
         if ( checkProtocol )
         {
-            try
-            {
                 if ( !urlValidator.validate( metadataUrl ) )
-                {
-                    ContinuumProjectBuildingResult res = new ContinuumProjectBuildingResult();
-                    res.addError( ContinuumProjectBuildingResult.ERROR_PROTOCOL_NOT_ALLOWED
);
-                    return res;
-                }
-            }
-            catch ( FormicaException e )
             {
-                //can't be thrown
+                ContinuumProjectBuildingResult res = new ContinuumProjectBuildingResult();
+                res.addError( ContinuumProjectBuildingResult.ERROR_PROTOCOL_NOT_ALLOWED );
+                return res;
             }
         }
 

Modified: continuum/trunk/pom.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/pom.xml?rev=685326&r1=685325&r2=685326&view=diff
==============================================================================
--- continuum/trunk/pom.xml (original)
+++ continuum/trunk/pom.xml Tue Aug 12 14:32:16 2008
@@ -756,6 +756,11 @@
         </exclusions>
       </dependency>
       <dependency>
+        <groupId>org.apache.httpcomponents</groupId>
+        <artifactId>httpclient</artifactId>
+        <version>4.0-alpha4</version>
+      </dependency>
+      <dependency>
         <groupId>org.codehaus.plexus</groupId>
         <artifactId>plexus-velocity</artifactId>
         <version>1.1.4</version>



Mime
View raw message