Error: Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not b

本文介绍了当使用Maven命令时遇到插件不可用的问题及其解决方法。主要原因是本地插件下载不完整或损坏,解决方案为删除对应插件目录并重新构建。

当运行 mvn clean, mvn install, mvn help:system时,会出现以下waring和error时,是因为当前使用的本地中的plugin不可用。可能是第一次下载没下载成功,没下载完全导致的。所以解决办法就是先删除本地下载失败的插件,然后重新build。

解决办法:删除本地的相应目录下的plugins,从我的错误中可以看出,我的plugin不可用所指的目录是org.apache.maven.plugins。所以本人先删除本地仓库中此目录下的所有文件,然后重新build一次即可。

Warning: The POM for org.apache.maven.plugins:maven-clean-plugin:jar:2.5 is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details

Error: Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolve

解决方法:
删除自己修改的仓库的的插件目录下的所有文件,重新build
如:C:\Software\maven\repo\org\apache\maven\plugins
删除此目录下的所有文件,然后重新build,如:mvn clean

ERROR] Plugin org.apache.maven.plugins:maven-surefire-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-surefire-plugin:jar:2.5: Could not transfer artifact org.apache.maven.plugins:maven-surefire-plugin:pom:2.5 from/to tplink-mvn (http://rdsource.tp-link.net/maven-public/): Transfer failed for http://rdsource.tp-link.net/maven-public/org/apache/maven/plugins/maven-surefire-plugin/2.5/maven-surefire-plugin-2.5.pom: Unknown host rdsource.tp-link.net: Name or service not known -> [Help 1] [ERROR] Plugin org.apache.maven.plugins:maven-surefire-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-surefire-plugin:jar:2.5: Failure to transfer org.apache.maven.plugins:maven-surefire-plugin:pom:2.5 from http://rdsource.tp-link.net/maven-public/ was cached in the local repository, resolution will not be reattempted until the update interval of tplink-mvn has elapsed or updates are forced. Original error: Could not transfer artifact org.apache.maven.plugins:maven-surefire-plugin:pom:2.5 from/to tplink-mvn (http://rdsource.tp-link.net/maven-public/): Transfer failed for http://rdsource.tp-link.net/maven-public/org/apache/maven/plugins/maven-surefire-plugin/2.5/maven-surefire-plugin-2.5.pom -> [Help 1] [ERROR] Plugin org.apache.maven.plugins:maven-surefire-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-surefire-plugin:jar:2.5: Failure to transfer org.apache.maven.plugins:maven-surefire-plugin:pom:2.5 from http://rdsource.tp-link.net/maven-public/ was cached in the local repository, resolution will not be reattempted until the update interval of tplink-mvn has elapsed or updates are forced. Original error: Could not transfer artifact org.apache.maven.plugins:maven-surefire-plugin:pom:2.5 from/to tplink-mvn (http://rdsource.tp-link.net/maven-public/): Transfer failed for http://rdsource.tp-link.net/maven-public/org/apache/maven/plugins/maven-surefire-plugin/2.5/maven-surefire-plugin-2.5.pom
最新发布
12-12
评论 9
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值