1.现象
报错日志1:
Could not transfer artifact com.zhqc.dataplatform:zhqc-datadev-datasource-plugin:jar:2.0.0-SNAPSHOT from/to releases
报错日志2:
was cached in the local repository, resolution will not be reattempted until the update inter
报错日志3:
Return code is: 400 , ReasonPhrase:Repository version policy: RELEASE does n
2.解决思路
第一:idea invalid cache,然后maven的reload project.,没有解决。
第二:不通过idea打包,直接通过maven命令打包
第三: 检查zhqc-datadev-datasource-plugin 是否在中央仓库存在。确实存在
第四:检查本地仓库是否存在,本地也存在。
第五:检查settings.xml的设置是否正确,主要是仓库(也可以看打包日志)
第六:检查本地idea的pom包是否设置了其他仓库(这个可以看打包日志看出来)
发现以上步骤都试过了没有解决问题
3.解决方法
最终请教同事,解决了这个问题。只需要在idea中修改下maven的设置。
找到File->Settings->Build,Execution,Deployment->Build Tools->Maven的菜单栏
然后勾选Always update snapshots.重新打包成功。