How to set build description if build times out?

39 views
Skip to first unread message

Matthew...@diamond.ac.uk

unread,
Jun 19, 2012, 5:32:01 AM6/19/12
to jenkins...@googlegroups.com
The build timeout plugin (https://wiki.jenkins-ci.org/display/JENKINS/Build-timeout+Plugin) has a job configuration checkbox "Writing the build description" (I think this was added in 1.9). However, there is nowhere to actually set the text of the build description in the event of a timeout.

Where can I set this?

Thanks


--
This e-mail and any attachments may contain confidential, copyright and or privileged material, and are for the use of the intended addressee only. If you are not the intended addressee or an authorised recipient of the addressee please notify us of receipt by returning the e-mail and do not use, copy, retain, distribute or disclose the information in or attached to the e-mail.
Any opinions expressed within this e-mail are those of the individual and not necessarily of Diamond Light Source Ltd.
Diamond Light Source Ltd. cannot guarantee that this e-mail or any attachments are free from viruses and we cannot accept liability for any damage which you may sustain as a result of software viruses which may be transmitted in or with the message.
Diamond Light Source Limited (company no. 4375679). Registered in England and Wales with its registered office at Diamond House, Harwell Science and Innovation Campus, Didcot, Oxfordshire, OX11 0DE, United Kingdom




Jesse Farinacci

unread,
Jun 19, 2012, 6:37:09 AM6/19/12
to jenkins...@googlegroups.com
Greetings,

On Tue, Jun 19, 2012 at 5:32 AM, <Matthew...@diamond.ac.uk> wrote:
> The build timeout plugin (https://wiki.jenkins-ci.org/display/JENKINS/Build-timeout+Plugin) has a job configuration checkbox "Writing the build description" (I think this was added in 1.9). However, there is nowhere to actually set the text of the build description in the event of a timeout.
>
> Where can I set this?
> Thanks

You can't. Check out:

https://github.com/jenkinsci/build-timeout-plugin/blob/master/src/main/java/hudson/plugins/build_timeout/BuildTimeoutWrapper.java#L106
https://github.com/jenkinsci/build-timeout-plugin/blob/master/src/main/resources/hudson/plugins/build_timeout/Messages.properties#L3

-Jesse

--
There are 10 types of people in this world, those
that can read binary and those that can not.

Matthew...@diamond.ac.uk

unread,
Jun 19, 2012, 6:50:40 AM6/19/12
to jenkins...@googlegroups.com
I see, it uses a standard message text. That's good enough for me - the help text wasn't clear, that's all.

cjo

unread,
Jun 19, 2012, 7:02:29 AM6/19/12
to jenkins...@googlegroups.com
From the code, it looks like the build description is hard coded, you cannot specify your own in this case.

The description set is 
"Build timed out (after {0} minutes). Marking the build as {1}."

where {0} is the time period it aborted at
and {1} is either "aborted" or "failed" depending on checkbox "Fail the build"

If you want your own message you could use the descriptor setter plugin, which can write a different message for failed /aborted builds, (Advanced section)

and you can use the Regular expression to search for the above message in the log.

Chris
Reply all
Reply to author
Forward
0 new messages