You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
trigger on new upstream build (same resource versions) #92
We have a job sequence a->b->c->d, where if d fails, we want to rerun a, b, c, and d. Re-running a does not trigger b because the resource versions have not changed. So we have to re-run a, wait for it to finish, re-run b, wait, re-run c, wait, and re-run d.
We would like concourse to re-run b, c, and d without manual intervention when we re-run a.
Hi there. I have a similar related issue. I use the pipeline for orchestration of cloud formation tasks whereby I tear down the infrastructure each night and want to rebuild from scratch each morning. I can use a time trigger which will happily invoke the first job but subsequent jobs don't activate as the sha on the input repo hasn't changed. I want to rebuild similar a->b->c without change to input resource.
@paulieborg I don't think that's a good idea. Pipelines are a dependency chain; if no dependencies between jobs are new, the downstream job shouldn't trigger. Even as an opt-in feature I think it would do a disservice to the mental model.
If something has changed in the real world but the resources aren't expressing that, it sounds like something is either being done by resources out-of-band (i.e. tasks, which should not have side-effects in the mental model) or a resource is not sufficiently capturing the external state in its version.
Heh @vito - thanks for the response. I've had similar feedback from peers and I can work around this using the feature listed here: https://github.com/starkandwayne/concourse-tutorial/tree/master/12_publishing_outputs
It allows me to start the pipeline by forcibly pushing a change to the repo and causing subsequent dependencies to be triggered after. It is not completely ugly.
I was more curious if there was an option to trigger a job, simply based on the prior job succeeding and 'ignore' the fact that the resource has not changed. This is for my specific use case but I can think of some others that are not unheard of:
Re-run a same version deployment job + smoke tests because a target system was lost.
Re-run a set of dependent test jobs again to see if they fail a second time.
Re-run a dependency job chain to simply check if a target state has changed (and fail if it has)
I'm willing to accept I'm doing it wrong so don't take this as disagreement - more that the current model doesn't suit my use case and I might need to consider a different tool.
@paulieborg A reasonable way to do those kinds of things (which I would argue that, again, are pointing at something missing with the use of resources) may be to shim in a time resource as an output of the upstream job, and have downstreams dependent on it. This expresses that at least some change has happened over time and that dependents should update.
For example:
resources:
- name: forcetype: timesource: {interval: 24000h} # ideally this could be disabledjobs:
- name: aplan:
- # ... do stuff ...
- put: force
- name: bplan:
- get: forcepassed: [a]trigger: true
- # ... do stuff ...
- put: force
- name: cplan:
- get: forcepassed: [b]trigger: true
- # ... do stuff ...
- put: force
I'm gonna close this issue for now though since I think we've covered it pretty well and why we won't bake this in as a first-class feature. The above seems like a reasonable workaround.
Activity
concourse-bot commentedon Jul 31, 2015
Hi there!
We use Pivotal Tracker to provide visibility into what our team is working on. A story for this issue has been automatically created.
The current status is as follows:
This comment, as well as the labels on the issue, will be automatically updated as the status in Tracker changes.
paulieborg commentedon Jul 25, 2016
Hi there. I have a similar related issue. I use the pipeline for orchestration of cloud formation tasks whereby I tear down the infrastructure each night and want to rebuild from scratch each morning. I can use a time trigger which will happily invoke the first job but subsequent jobs don't activate as the sha on the input repo hasn't changed. I want to rebuild similar a->b->c without change to input resource.
vito commentedon Jul 25, 2016
@paulieborg I don't think that's a good idea. Pipelines are a dependency chain; if no dependencies between jobs are new, the downstream job shouldn't trigger. Even as an opt-in feature I think it would do a disservice to the mental model.
If something has changed in the real world but the resources aren't expressing that, it sounds like something is either being done by resources out-of-band (i.e. tasks, which should not have side-effects in the mental model) or a resource is not sufficiently capturing the external state in its version.
paulieborg commentedon Jul 25, 2016
Heh @vito - thanks for the response. I've had similar feedback from peers and I can work around this using the feature listed here:
https://github.com/starkandwayne/concourse-tutorial/tree/master/12_publishing_outputs
It allows me to start the pipeline by forcibly pushing a change to the repo and causing subsequent dependencies to be triggered after. It is not completely ugly.
I was more curious if there was an option to trigger a job, simply based on the prior job succeeding and 'ignore' the fact that the resource has not changed. This is for my specific use case but I can think of some others that are not unheard of:
Re-run a same version deployment job + smoke tests because a target system was lost.
Re-run a set of dependent test jobs again to see if they fail a second time.
Re-run a dependency job chain to simply check if a target state has changed (and fail if it has)
I'm willing to accept I'm doing it wrong so don't take this as disagreement - more that the current model doesn't suit my use case and I might need to consider a different tool.
Thanks again
vito commentedon Aug 8, 2016
@paulieborg A reasonable way to do those kinds of things (which I would argue that, again, are pointing at something missing with the use of resources) may be to shim in a
timeresource as an output of the upstream job, and have downstreams dependent on it. This expresses that at least some change has happened over time and that dependents should update.For example:
I'm gonna close this issue for now though since I think we've covered it pretty well and why we won't bake this in as a first-class feature. The above seems like a reasonable workaround.
bump a *bunch* of dependencies
bump atc fly go-multierror