删除.m2本地仓库后建立maven项目报错问题

报错如下:

Downloading from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-archetype-plugin/maven-metadata.xml [WARNING] Could not transfer metadata org.apache.maven.plugins:maven-archetype-plugin/maven-metadata.xml from/to alimaven (http://maven.aliyun.com/nexus/content/groups/public/): Failed to transfer file: http://maven.aliyun.com/nexus/content/groups/public/org/apache/maven/plugins/maven-archetype-plugin/maven-metadata.xml. Return code is: 500 , ReasonPhrase:Internal Server Error.

由上可知:

无法从阿里云远程仓库中下载 maven-metadata.xml ,故报错

解决方案:

把 apache-maven-3.5.2\conf\settings.xml 中配置的阿里云远程仓库注释掉,改用默认的远程仓库下载即可,成功建立maven项目后觉得下载依赖的jar包慢再把注释去掉就好了

猜你喜欢

转载自blog.csdn.net/Cushier/article/details/82223656
今日推荐