如何在构建依赖项之前将Hudson构建延迟? [英] How to delay a Hudson build until its dependencies are built?

查看:55
本文介绍了如何在构建依赖项之前将Hudson构建延迟?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们的构建包括两个项目,一个库项目和一个依赖于库项目的Web前端项目.

Our build consists of two projects, a library project and a web front end project that depends on the library project.

Hudson作业是从maven pom.xml文件配置的,并且依赖项在Hudson上显示为下游/上游项目.这两个作业都使用"poll SCM"构建触发器,并且只有一个项目发生更改时,一切都会按预期进行.

The Hudson jobs are configured from the maven pom.xml files and the dependency appears on Hudson as downstream/upstream project. Both jobs use the "poll SCM" build trigger and everything works as intended when only one the projects changes.

当提交包含两个项目中的更改时,就会出现问题,因此Hudson同时启动两个项目的构建,并且通常Web项目构建失败,因为它使用的是库项目的旧版本.

The problem arises when a commit contains changes in both projects, so Hudson starts a build of both projects at the same time and usually the web project build fails because it is using an older version of the library project.

如果存在运行库项目的构建,我可以配置Hudson来延迟Web项目构建的执行吗?

Can I configure Hudson to delay the execution of the web project build if there is a build running the library project?

推荐答案

Web项目和其他项目不是位于版本控制的不同区域吗?另一方面,您可以定义上游或下游依赖关系,并且仅在构建顺利的情况下才说开始.

Isn't the web project and the other project located in a different area of the version control? ON the other hand you can define upstream or downstream dependencies and say only start if the build went well.

这篇关于如何在构建依赖项之前将Hudson构建延迟?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆