新建了一个项目,在执行构建任务时,出现了失败,报错信息如下:

[FATAL] Non-resolvable parent POM for com.ydwy:tyzf-webservice:0.0.1-SNAPSHOT: Could not find artifact com.ydwy:tyzf:pom:0.0.1-SNAPSHOT and 'parent.relativePath' points at wrong local POM @ line 5, column 10

于是我找到此项目目录下的pom.xml文件,找到第五行,没发现什么问题,于是转交开发同事查此问题,经过多翻尝试,问题依然没有解决。

仔细阅读报错说明'parent.relativePath',原来问题出在此,这个pom文件在编译的时候,引用了父关联路径,于是修改了jenkins的配置,问题轻松得到了解决,方法如下:

源码管理这里的Repository URL的路径指到原路径的上一级路径,保存重新构建,成功。

jenkins构建时报错:Could not find artifact com.ydwy:tyzf:pom:0.0.1-SNAPSHOT and 'parent.relativePath' points at wrong local POM @ line 5, column 10

原理:我们在编译该项目时,是隶属于一个大项目下的子项目,他与其他项目之间存在互相调用的关系,所以需要把大项目下其他相关联的子项目文件也取下来,编译后各个子项目会生成各自的target包,编译完成后,我们只要传输相应的子项目的war包即可。

jenkins构建时报错:Could not find artifact com.ydwy:tyzf:pom:0.0.1-SNAPSHOT and 'parent.relativePath' points at wrong local POM @ line 5, column 10

 

相关文章:

  • 2021-04-19
  • 2021-05-27
  • 2021-11-17
  • 2021-04-24
  • 2021-12-20
  • 2021-10-08
  • 2021-04-13
猜你喜欢
  • 2023-02-16
  • 2021-11-28
  • 2021-11-22
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案