Queue a build as of a given change

How do I use OpenAPI to queue a build as of a given change, and with extra parameters?

There is SQueuedBuild.addToQueue(), but that doesn't allow specifying any extra parameters.

Basically, I'm looking for an equivalent of
* the "Run ..." dialog in the web GUI
* https://confluence.jetbrains.com/display/TCD8/REST+API#RESTAPI-TriggeringaBuild in REST API (which also allows specifying all kinds of params)

2 comments
Comment actions Permalink

Hi Sam,

AFAIK, Build queueing process looks like:
* Obtain BuildCustomizerFactory (using spring beans)
* Create new BuildCustomizer using factory from previous step
* Change something in build customizer (set parameters in your case)
* Invoke BuildCustomizer#createPromotion(), you'll get BuildPromotion
* Invoke addToQueue on build promotion from previous step.

It's a bit complicated. J

Also as example you can see how api used in rest api plugin sources.


Regards,

Vladislav.

0
Comment actions Permalink

Thanks, Vladislav. That's very helpful.

Now that I know what to look for (BuildCustomizerFactory) I see that this has already been answered before (e.g. here :-)).

Thanks for including all the detail, too.

0

Please sign in to leave a comment.