Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Bamboo plugin not found on agents

Jamie Martini March 7, 2016

I am developing a custom Bamboo task plugin and having some issues with deployment onto our server. When developing on a localhost instance (running atlas-debug/atlas-run) the plugin executes successfully and the plugin results are as expected. When I upload the plugin to a test server instance of Bamboo that has remote agents, running a build plan that contains the new plugin task results in errors on the agents:

Could not execute task '<task name>' no Plugin with key '<task key>' is installed.

Looking at the agents in use, the plugin is being added to the plugins/user-installed/ folder. I have tried restarting the agents and the server after installing the plugin, but I still get the same error. Bamboo versions are the same for localhost instances and the server version.

Has anyone experienced this before? Is there a required step that would make installing a plugin using a localhost version of Bamboo different then an instance running on a server? Is there any way to get more info about why the plugin is not being found on the agents, such as where they are searching for the plugins? All error logs I have seen have not given any more information then the above line. 

Thank you for any insight. 

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

5 votes
Answer accepted
Steffen Opel _Utoolity_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 7, 2016

This usually happens when the add-on depends on a class that is only available on the server, but not on the agent, see section Manager Classes in Accessing Bamboo Components From Plugin Modules:

There are many managers for different areas of functionality in Bamboo. Not all managers are available on both the Server and any agents that might be running. The following table lists some of the more commonly used ones: [...]

In other words, your add-on has been installed on the agent, but cannot be enabled (aka started) due to a missing dependency. Such a conflict (or any other add-on issue) is reported to the agent log during agent startup or plugin installation, i.e. when the plugin subsystem tries to enable the add-on in question. The agent log is usually called atlassian-bamboo-agent.log and located in the agent's home directory (see Logging in Bamboo for details).

'Local' remote agents

The Difference between Local agents and Remote Agents in terms of Bamboo concepts is that the former runs in-process within the server JVM, whereas the latter runs out-of-process in its own JVM.

Consequently you can also run a remote agent on your local system, i.e. following the Bamboo remote agent installation guide to start and targeting your Bamboo test instance allows you to a) tail the remote agent log, and even b) debug your Bamboo agent remotely (requires additional configuration).

Jamie Martini March 7, 2016

Thanks Steffen! 

I was able to locate the log that contained an unsatisfied dependency error in the agent's home directory under log/atlassian-bamboo.log.

The unsatisfied dependency was com.atlassian.sal.api.ApplicationProperties. This class is in the constructor of the default bamboo plugin component if created using the "atlas-create-bamboo-plugin" script. Since I didn't think I touched this file at all, I ran a test with a brand new plugin. I followed the steps for the Hello World plugin as documented here. When I tried to deploy this on the server, I got the same unsatisfied dependency. There seems to be something missing from the default configuration when using "atlas-create-bamboo-plugin". I wan't able to resolve this dependency using the @ComponentImport tag or by using <component-import /> in the atlassian-plugin.xml file. Since this component only seems to be used for running tests, I have removed it for now and everything is running as expected on my server. Do you know how I would properly resolve this dependency?

 

 

Steffen Opel _Utoolity_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 7, 2016

Not immediately - we've had similar issues with e.g. the EncryptionService interface, but we actually use the ApplicationProperties ourselves, so I would need to ponder this a bit. Unfortunately the Bamboo portion of the SDK is not as well maintained as others, so to narrow down the scope it would be good to know which SDK version you are using for atlas-create-bamboo-plugin?

TAGS
AUG Leaders

Atlassian Community Events