Ability to cancel build with failure status by servicemessage

Answered

We have a configuration that runs a build with parallel tasks. If one task fails the whole build should fail terminating the other tasks.
For now we accomplish this with  ##teamcity[buildStop] service message. 
But in that case have 2 problems:
1. Nobody gets informed of the build failed. (there are no Notification rules on canceled builds)
2. The configuration status in the projects' home view set to the last non-canceled build. It could be "success".

I tried to add last step with 'exeute always' and servicemessage to change current buld status to FAUILURE but this does nothing.

0
2 comments

Hi Dmitry! 

When you added the last step with Failure build message did you also change "Build failure condition" to fail a build if an error message is logged? 

1
Avatar
Permanently deleted user

Thanks for reply.  The feature Build failure condition  to fail a build if an error message is logged helped me out. Now a can opt out of canceling the build

0

Please sign in to leave a comment.