getLogger().info( emsg );
return null;
}
-
+
+ if ( urlFailureCache.hasFailedBefore( url ) )
+ {
+ throw new NotFoundException( "Url has failed before and cache-failure is enabled on this connector" );
+ }
+
Wagon wagon = null;
try
- {
+ {
RepositoryURL repoUrl = remoteRepository.getURL();
String protocol = repoUrl.getProtocol();
wagon = (Wagon) wagons.get( protocol );
}
catch ( NotFoundException e )
{
- // Do not cache url here.
+ // public repositories may be slow to access, and many request will fail when
+ // muliple repositories are "merged" by archiva via proxies.
+ // so caching "not found" is usefull here to enhance archiva response-time
+ urlFailureCache.cacheFailure( url );
throw e;
}
catch ( NotModifiedException e )