Failed to execute goal on project xxx: Could not resolve dependencies for project com

错误描述:

Failed to execute goal on project xxx: Could not resolve dependencies for project com.jd.ka:xxx:war:0.0.1-SNAPSHOT: The following artifacts could not be resolved: com.jd.ka:ka-explore-service:jar:0.0.1-SNAPSHOT, com.jd.ka:ka-explore-rpc:jar:0.0.1-SNAPSHOT: Failure to find com.jd.ka:ka-explore-service:jar:0.0.1-SNAPSHOT in http://artifactory.jd.com/libs-snapshots-local was cached in the local repository, resolution will not be reattempted until the update interval of snapshots_local has elapsed or updates are forced -> [Help 1]
解决方案:

1、首先,相信既然你犯了这样的错误,那么你的项目应该也是多个module的。就像下图:

2、我这里就举个例子,所以应用的也就是web和service这两个项目。

3、两个项目都继承父项目

4、在模块中web依赖于service,在web中执行完clean和install之后,本地仓库也存在依赖,但是在service中进行install就会出现

    Failed to execute goal on project …: Could not resolve dependencies for project …

这样测错误,最后发现原来是自己没有首先对父项目也就是interface-test项目进行clean和install ,

5、总结、在父项目下有的子项目在首次运行clean 和install前应该先运行父项目的clean和install

原文链接:https://blog.csdn.net/qq_41946557/article/details/105121115

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值