mirror of https://github.com/apache/archiva.git
[MRM-460] correct the default configuration for failure policies
Submitted by: nicolas de loof git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@576030 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
20ed6eb362
commit
5531453210
|
@ -49,7 +49,7 @@
|
|||
<snapshots>disabled</snapshots>
|
||||
<releases>once</releases>
|
||||
<checksum>fix</checksum>
|
||||
<cache-failures>cache</cache-failures>
|
||||
<cache-failures>cached</cache-failures>
|
||||
</policies>
|
||||
<whiteListPatterns>
|
||||
<whiteListPattern>**/*</whiteListPattern>
|
||||
|
@ -63,7 +63,7 @@
|
|||
<snapshots>disabled</snapshots>
|
||||
<releases>once</releases>
|
||||
<checksum>fix</checksum>
|
||||
<cache-failures>cache</cache-failures>
|
||||
<cache-failures>cached</cache-failures>
|
||||
</policies>
|
||||
<whiteListPatterns>
|
||||
<whiteListPattern>javax/**</whiteListPattern>
|
||||
|
|
|
@ -29,13 +29,12 @@ import java.util.List;
|
|||
import java.util.Properties;
|
||||
|
||||
/**
|
||||
* {@link PreDownloadPolicy} to check if the requested url has failed before.
|
||||
* {@link PreDownloadPolicy} to check if the requested url has failed before.
|
||||
*
|
||||
* @author <a href="mailto:joakime@apache.org">Joakim Erdfelt</a>
|
||||
* @version $Id$
|
||||
*
|
||||
* @plexus.component role="org.apache.maven.archiva.policies.PreDownloadPolicy"
|
||||
* role-hint="cache-failures"
|
||||
* role-hint="cache-failures"
|
||||
*/
|
||||
public class CachedFailuresPolicy
|
||||
extends AbstractLogEnabled
|
||||
|
@ -43,7 +42,7 @@ public class CachedFailuresPolicy
|
|||
{
|
||||
/**
|
||||
* The CACHED policy indicates that if the URL provided exists in the
|
||||
* cached failures pool, then the policy fails, and the download isn't even
|
||||
* cached failures pool, then the policy fails, and the download isn't even
|
||||
* attempted.
|
||||
*/
|
||||
public static final String CACHED = "cached";
|
||||
|
@ -66,7 +65,7 @@ public class CachedFailuresPolicy
|
|||
if ( !options.contains( policySetting ) )
|
||||
{
|
||||
// No valid code? false it is then.
|
||||
getLogger().error( "Unknown checksum policyCode [" + policySetting + "]" );
|
||||
getLogger().error( "Unknown check-failures policyCode [" + policySetting + "]" );
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -87,7 +86,7 @@ public class CachedFailuresPolicy
|
|||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
getLogger().debug( "OK to fetch, check-failures detected no issues." );
|
||||
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue