【记】一次common模块导入无效的bug

首先Maven clean install无用

然后idea清除缓存重启无用

pom.xml文件重载无效

正确解决路径:

1.检查common模块的父工程导入和自身模块的声明是否正确

默认是继承父工程的groupid,可以不用再声明

2.检查子工程是否引入正确的common,org不要写成ogr了

3.修改完所有的common模块相关声明然后父工程clean报version缺失错误

ERROR The project org.mumu:comsumer:1.0 (D:\学习\javacode\eureka\consumer\pom.xml) has 6 errors ERROR 'dependencies.dependency.version' for org.springframework.boot:spring-boot-starter-web:jar is missing. @ line 23, column 21 ERROR 'dependencies.dependency.version' for org.springframework.boot:spring-boot-starter-actuator:jar is missing. @ line 27, column 21 ERROR 'dependencies.dependency.version' for org.springframework.boot:spring-boot-devtools:jar is missing. @ line 31, column 21

如果是父工程管理了版本那么子工程是可以不用声明version的,此时去检查父工程的pom

检查子模块、groupid等信息

检查properties是否正常,不能爆红,复制粘贴注意只能有一个properties

检查版本管理,注意这里是dependencyManagement、dependencies、dependency三个标签

至此重新clean install,common模块成功导入

相关推荐
小稀土12314 分钟前
私有化研发协同系统并行期:旧 Jira 与新 Git 并存 6 条数据规则
git
Madison-No71 小时前
Git版本控制工具(二)
git
Brookty4 小时前
Git 与 GitHub|第一阶段:仓库、版本历史与 Git 对象模型(上篇)
git·github
8年车载测试18 小时前
车载测试中如何通过 Jira 平台提交 Bug:操作步骤与关键要点
bug·jira·uds诊断·hil测试·uds自动化测试·ecu刷写测试·canoe工具
Kimnol18 小时前
我的第一次 Git 贡献:从 fork 到合并 PR #3130
git
qq_3660862220 小时前
idea项目重新启动时报错找不到jar
pycharm·intellij-idea·jar
鬼手点金1 天前
消息的四种角色
java·前端·人工智能·git·深度学习
硅基手札1 天前
SPI技术系列 13 · SPI 调试与排查
linux·运维·stm32·单片机·嵌入式硬件·bug
李永奉1 天前
杰理可视化SDK开发-【BUG】AC7006F8芯片开启一拖二和双麦通话语音算法后,设置触摸音在唤醒语音助手和通话时触摸音没作用问题
单片机·嵌入式硬件·mcu·物联网·电脑·bug
齐 飞2 天前
idea中git误操作撤回git reset --hard ‘HEAD@{1}‘
java·git·intellij-idea