How to make a plugin listen to builds being stopped?

9 views
Skip to first unread message

Sebastian Schuberth

unread,
Sep 1, 2015, 9:38:02 AM9/1/15
to Jenkins Developers
Hi,

I'd like to extend the parameterized trigger plugin with an option to stop triggered builds when the parent build is stopped (see JENKINS-11257). Being new to plugin development, I have no idea how to do that. Should I use a BuildListener or RunListener to globally listen for builds to be finished, and sort out those what were not triggered by the parameterized trigger plugin, or should I use a BuildWrapper with parent builds that optionally stops triggered builds in a post-build step, or ...

I simply don't know the options. Hints anyone?

Regards,
Sebastian

Robert Sandell

unread,
Sep 1, 2015, 11:38:47 AM9/1/15
to jenkin...@googlegroups.com
You could try to catch the InterruptedException that is thrown while waiting for the build result and take action from there.

/B

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/e78e2ee9-8bd1-4d80-a036-5bdcded23a3e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Robert Sandell
Software Engineer
CloudBees Inc.
Reply all
Reply to author
Forward
0 new messages