mirror of https://github.com/apache/maven.git
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:
parent
6fdbe554dd
commit
94ab6a4076
|
@ -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" ) )
|
||||
|
|
Loading…
Reference in New Issue