It's not the same without you
Join the community to find out what other Atlassian users are discussing, debating and creating.
We've written a plugin that triggers deployment plans programatically. After upgrading from 5.6 to 5.9 it has broken due to a backwards incompatible change in the bamboo api. Previously we used
Deploymentcontext context = deploymentExecutionService.prepareDeploymentContext(environment, version, reason); deploymentExecutionService.execute(context);
However in 5.9, deploymentExecutionService.execute now takes an environment and an EnvironmentTriggeringAction. I can't figure out how i'm supposed to create an EnvironmentTriggeringAction since it's an interface. i found EnvironmentTriggeringActionFactory, but that's also an interface. I tried wiring it in just like a service, but it doesn't get wired in. I can't find anything else that would let me create an EnvironmentTriggeringAction.
How am i supposed to trigger deploy plans now?
Also, tangentially, why was backwards compatibility broken without warning in the api changelog?
How am i supposed to trigger deploy plans now?
Good question, I hope an Atlassian Bamboo team member chimes in here.
Also, tangentially, why was backwards compatibility broken without warning in the api changelog?
Likewise a good question - we had stumbled over a significant (and as of today still undocumented) Bamboo 5.9 API change as well, and I have requested a resp. changelog update two month ago already, which you might want to watch/vote/comment on accordingly:
While the minor sorting issue mentioned there too has meanwhile been (silently) fixed, the Changes for 5.9 documentation itself has not yet been amended in any way.
1) The change had to be done because old logic was broken. There is no meaningful implementation for the old interface and it had to be removed. See: BAM-15501
2) Moreover, the correct method to be called when triggering deployment is NonBlockingPlanExecutionService.tryToStart(
environment, environmentTriggeringAction). The method's signature:
Future<ExecutionRequestResult> tryToStart(@NotNull Triggerable triggerable, @NotNull BuildDetectionAction buildDetectionAction);
3) EnvironmentTriggeringAction is an interface because plugins triggering deployments are supposed to implement it. You can find examples in Bamboo source code.
4) If you want to use one of existing implementations of EnvironmentTriggeringAction, EnvironmentTriggeringActionFactory is available to plugins. In fact, deployment triggers built-in in Bamboo are implemented as plugins. They wouldn't work if the factory wasn't available to them.
(did you put <component-import> statement into your atlassian-plugin.xml?)
This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.
Read moreBamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...
Connect with like-minded Atlassian users at free events near you!
Find a groupConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.
Start an AUGYou're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.