Trigger an operation after build complete in RTC server
I `m developing a RTC extension for trigger an custom operation after a build request is success.The question is which the operationId shoud i use ?
|
Accepted answer
It is possible. You have to create an event handler extension, instead of an advisor or follow-up. The event category you can use is com.ibm.team.build.category.BuildResultChanged. As Ralph says it is an asynchronous operation, so it will begins some seconds after the build is completed and if it fails or throws an exception no message will be displayed to the user.
Every operation you try to perform with this extension will be performed by "admin" user so they should be permitted to everyone unless you implement an ImpersonationRunnable operation, and trigger it using the IImpersonationService. In this case you can set the user you want to perform the operation. han huynh selected this answer as the correct answer
Comments Good catch, Michele.
han huynh
commented Dec 06 '15, 10:54 p.m.
I can not find this com.ibm.team.build.category in RTC SDK 5. Is there any example how to use this event category? 1
Michele Pegoraro
commented Dec 07 '15, 4:07 a.m.
You can't find it in the SDK: it's the value that you have to use in your plugin.xml (it is like operationId for advisors).
han huynh
commented Dec 08 '15, 3:29 a.m.
Hi Ralph Schoon, Michele Pegoraro, i did it. Thanks you!
han huynh
commented Dec 08 '15, 4:50 a.m.
BTW, Can you show me what is the eventCategory for Project area, Build definition changing(rename, delete)?
2
Michele Pegoraro
commented Dec 08 '15, 4:59 a.m.
In a very empirical way :-)
I tried com.ibm.team.workitem.event.stateChanged, but it does not work. Do you have any idea for Project area, Build definition changing(rename, delete) event? Thank you!
showing 5 of 7
show 2 more comments
|
One other answer
Ralph Schoon (63.5k●3●36●46)
| answered Dec 04 '15, 3:36 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
This is the list of extension points: https://jazz.net/wiki/bin/view/Main/CustomPreconditionsTable#operations
However, there is no extension point that does what you want. The reason is, that the build runs asynchronously and all the server knows about the build is sent to it from the build engine. If you want to do additional automation during or at the end of the build, I would suggest to use the client API and perform that operation as a build step. |
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.