maven依赖项目deploy发布工程至私服时报错问题

版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://blog.csdn.net/yangzaizi/article/details/89332154

场景:aas-core-auth-client想打包成项目基础jar包发布至maven私服,所有项目依赖于汇总的pom,aas-core-auth-client依赖于aas-core-common,在deploy发布aas-core-auth-common时没有问题(common没有依赖项目中其他模块),aas-core-auth-client依赖于aas-core-auth-common项目,在deploy时报错:[ERROR] Failed to execute goal on project aas-core-auth-client: Could not resolve dependencies for project com.aas.mdf:aas-core-auth-client:jar:1.0.0-SNAPSHOT: Failed to collect dependencies at com.aas.mdf:aas-core-common:jar:1.0.0-SNAPSHOT: Failed to read artifact descriptor for com.aas.mdf:aas-core-common:jar:1.0.0-SNAPSHOT: Could not transfer artifact com.aas.mdf:aas-mdf:pom:1.0.0-SNAPSHOT from/to maven-central (http://localhost:8081/repository/maven-central/): Failed to transfer file: http://localhost:8081/repository/maven-central/com/aas/mdf/aas-mdf/1.0.0-SNAPSHOT/aas-mdf-1.0.0-SNAPSHOT.pom. Return code is: 400 , ReasonPhrase:Repository version policy: RELEASE does not allow version: 1.0.0-SNAPSHOT. -> [Help 1]

解决方案:

在parent项目运行install命令后,然后再进行clean和deploy模块aas-core-auth-client既可以解决问题。

展开阅读全文

没有更多推荐了,返回首页