maven 镜像问题

1、创建maven新项目时报错
[ERROR] Plugin org.apache.maven.plugins:maven-archetype-plugin:RELEASE or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-archetype-plugin:jar:RELEASE: Failed to resolve version for org.apache.maven.plugins:maven-archetype-plugin:jar:RELEASE: Could not find metadata org.apache.maven.plugins:maven-archetype-plugin/maven-metadata.xml in local (C:\Users\Administrator.m2\repository) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException
[ERROR] Maven execution terminated abnormally (exit code 1)
2、加载带svn的项目时报错
Error:svn: E155013: Can’t add ‘F:\workspace\ProjectSpace\UnionPay\DataPlatform.idea\libraries\Maven__org_glassfish_javax_servlet_3_1.xml’ to a parent directory scheduled for deletion

解决方法:maven安装目录下的settings.xml配置文件没有配置镜像

 
       

这样需要的东西会从maven的中央仓库下载,因为这个仓库是在国外,所以有一些会下载失败

所以重新配置了一下仓库地址

 
    
	 
	  alimaven
	  aliyun maven
	  http://maven.aliyun.com/nexus/content/groups/public/
	  central        
	
  

问题解决。在创建mvn项目时,注意设置,如图
maven 镜像问题_第1张图片

你可能感兴趣的:(开发环境)