act a bit smarter when the remote repo is timing out/offline

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@264956 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Brett Leslie Porter 2005-08-31 07:12:52 +00:00
parent 6fdbe554dd
commit 94ab6a4076
1 changed files with 10 additions and 2 deletions

View File

@ -147,6 +147,14 @@ public class ArtifactDownloader
{
HttpUtils.getFile( metaUrl, file, ignoreErrors, true, proxyHost, proxyPort, proxyUserName,
proxyPassword, false );
}
catch ( IOException e )
{
log( "WARNING: remote SNAPSHOT version not found, using local: " + e.getMessage() );
}
if ( file.exists() )
{
version = FileUtils.fileRead( file );
log( "Resolved version: " + version );
dep.setResolvedVersion( version );
@ -163,9 +171,9 @@ public class ArtifactDownloader
return true;
}
}
catch ( IOException e )
else
{
log( "WARNING: SNAPSHOT version not found, using default: " + e.getMessage() );
log( "WARNING: local SNAPSHOT version not found, using default" );
}
}
if ( !dep.getType().equals( "pom" ) )