Hudson pipelines
Can anyone help with this problem?
I have a test job, a downstream job, and a connection job. I want the merge job to run only if the downlink job succeeds.
If the test job fails and it still succeeds, I still want to start the connection job.
Does anyone know of a plugin that can help here?
The connection plugin is not good enough because I can configure it to run the connection job when the test AND the downstream succeeds, or start the connection regardless of whether the jobs succeed or fail. But don't start collaboration ONLY if the downstream succeeds.
Why do I want to do it like this? I want the pipeline jobs to be merged together, but only if the overall downstream job succeeds. If it fails, I want the conveyor to "break".
Adding more information to the original question: So I have a suite of tests (Test.1, Test.2, Test.3). I can run them separately from Hudson, they run, produce a result, and finish. I also want to be able to run them as part of a pipeline. Test.1 runs, exits, and then Test.2 runs. etc. So I have two different ways that I can run Test.1. Individual or as part of a pipeline. To help here I did Test.1, Test.2, etc. Parameterized (true / false). The default is false. So when I run Test.1 by default (false), the test starts and ends. When I run Test.1 with the True parameter, I would like it to run Test.2. This second bit I cannot do
Thanks a lot John
a source to share
Similar to Gareth_bowles, I would just link all jobs (no connection) and use the Hangson Parameterized Trigger plugin to trigger the dependent job even if the current job is not done. The only drawback is that you don't have jobs running in parallel.
Alternatively, you can use the Hangson Parameterized Trigger plugin to trigger temporary work after a test job regardless of the success of the test job. The temp job will always succeed (because it actually does nothing but initiate the merge job. That way, your test job (from the join job view) will always succeed, and only the downlink job determines if the join job is done ...
Edit
After realizing what you really want to do, namely run Test.N on its own or as part of a chain, I would go with my first suggestion. This means that Test.N always starts the Downstream.N job, regardless of whether Test.N succeeds or fails. You need the Hangson Parameterized Trigger plugin and set up two triggers. The first triggers the dependent job when the test job is successful or unstable, and the second trigger also starts the dependent job, but only when the test job fails. Don't forget to pass your parameters and you're done. Not very difficult.
a source to share
Can't you just skip the join plugin and make the merge work solely dependent on the transition work? This will satisfy your requirement for the merge job to run only when the downlink completes successfully, as long as you ensure that the Trigger even if assembly is unstable check box is not specified in the dependency definition in the downstream assembly.
a source to share