It's all about the answers!

Ask a question

Ant task to update work item with build results

Ananya Joisa (4552124) | asked Nov 26 '12, 4:15 a.m.
retagged Jun 10 '13, 3:42 p.m. by Morten Madsen (3052842)
Hi All,

I was looking for a task which would update the work item fields. What I am trying to do is copy the result of a build definition and update it in the work item comments field. I found a link :

I am looking for a task which has the functionality exactly opposite to this. A task that publishes build information to a work item. Could anyone please guide me.

Thanks for your help!

One answer

permanent link
Lauren Hayward Schaefer (3.3k11427) | answered Nov 26 '12, 7:33 a.m.
Hi Ananya,

I've accomplished this task of automatically commenting in a work item when a build completes with the build results by using build engine participants written in Java. is one of our current track build items, and you can see comments from Mr. Build that were automatically added when a build completed.  I'm in the process of writing a blog post with a full description of how I accomplished this.  In the meantime, I'll give you a few pointers....

Build engine participants are pieces of code that can be run before, during, or after a build.  The code to be executed is installed as a plugin in the JBE, and the participant is applied to the Jazz build definition so the engine knows to execute the code.  The JBE takes care of notifying the participant that it should be run; all you have to do is write the code that should be executed at the given time in the build process.  There are four major steps to complete in order to use build engine participants:  writing the build engine participant, installing the build engine participant in the JBE, installing the build definition configuration element and editor extensions in the RTC Eclipse client, and applying the build engine participant to the build. has some sample code for a build engine participant. explains how to update work items programmatically. has examples of how to work with the build api. has more information on the build engine participant I wrote.

Spencer Murata commented Nov 27 '12, 12:41 p.m.

 To elaborate on the Ant Task part, there is currently no Ant Task that will do what you describe, so you will have to go with a plugin like above.  Assuming that a build participant will still fit into your use case.  If you want an Ant Task like that then you should open an RFE.


Lauren Hayward Schaefer commented Apr 19 '13, 6:38 a.m.

The blog post where I discuss build engine participants is available here:

Ralph Schoon commented Apr 19 '13, 7:06 a.m.

Your answer

Register or to post your answer.