maven打包报错

今天使用自动发版时,突然报如下错误:

Failed to execute goal on project xxx: Could not resolve dependencies for project cn.sunline:xxx: Failed to collect dependencies at org.jetbrains:annotations:jar:RELEASE: Failed to read artifact descriptor for org.jetbrains:annotations:jar:RELEASE: Failed to resolve version for org.jetbrains:annotations:jar:RELEASE: Could not find metadata org.jetbrains:annotations/maven-metadata.xml in local (/usr/local/maven/repo) -> [Help 1]

问题排查:

1、验证本地环境是否能够install:

验证结果:可以install,但是有个警告(Some problems were encountered while building the effective model for cn.sunline:sunimp-app:jar:4.0.22
'dependencies.dependency.version' for org.jetbrains:annotations:jar is either LATEST or RELEASE (both of them are being deprecated) @ line 171, column 22
It is highly recommended to fix these problems because they threaten the stability of your build.
For this reason, future Maven versions might no longer support building such malformed projects.)

翻译:在构建cn.sunline: sunimpp -app:jar:4.0.22的有效模型时遇到了一些问题

'dependencies.dependency.version'jetbrains:annotations:jar要么是LATEST要么是RELEASE(两者都已被弃用)@第171行,第22列

强烈建议修复这些问题,因为它们会威胁到构建的稳定性。

由于这个原因,未来的Maven版本可能不再支持构建这种不规范的项目。

2、原因:服务器Maven版本可能不再支持构建这种不规范的项目

3、解决措施:

①将鼠标悬浮在RELEASE上,会自动显示版本

②将RELEASE改成提示版本即可

4、验证解决措施是否有效:

①修改版本后本地install没有警告

②服务上可以正常打包部署

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值