JDK 1.8.0 Compatilbility with Atlassian OnDemand Elastic Agent

I have created an agent in my VPC with an attached EBS snapshot.

In the /mnt/bamboo-ebs directory I have extraced the gzip file from the Oracle JDK page (https://jdk8.java.net/download.html) to /mnt/bamboo-ebs/jdk1.8.0

I then customised the /mnt/bamboo-ebs/bin/customise-extras.sh as attached

I then customised the /mnt/bamboo-ebs/profile-extras.sh as attached

I then created a snapshot, updated my elastic instance configuration and launched a new instance which hangs and there are many Java errors in the bamboo-elastic-agent.out file as shown in attachment.

Is this library supported? Can anyone shed any light on what causes these errors please? (p.s. I'm a newbie to Atlassian Bamboo and Java)

Many thanks (bamboo-elastic-agent.log) (customise-extras.txt) (profile-extras.txt)

4 answers

1 accepted

1 vote
Accepted answer

You can't start Bamboo (this applies both to the server and the agent) on JDK8 at the moment. There are some 3rd party dependencies that are incompatible with JDK8.

Note that the tThe JDK used to launch the agent is independent from the JDK used to run the builds - just create a JDK capability for your custom JDK.

Thanks for the answer @Przemyslaw Bruski.  Uninstalling JDK8 and then installing JDK7 did the trick.  I had to uninstall/reinstall and then reset my JAVA_HOME environment variable, but then restarting the service made things work. 

The first warning message is

2014-03-11 12:05:37,055 WARN [Thread-2] [PropertyPlaceholderConfigurer] Could not load properties from class path resource [bamboo-init.properties]: class path resource [bamboo-init.properties] cannot be opened because it does not exist

and the first error message is

2014-03-11 12:05:44,671 ERROR [Thread-2] [EventPublisherImpl] There was an exception thrown trying to dispatch event 'com.atlassian.plugin.event.events.PluginFrameworkStartingEvent@5d906340' from the invoker 'com.atlassian.plugin.event.impl.MethodSelectorListenerHandler$1$1@49bd724c'.

java.lang.RuntimeException: java.util.ArrayList cannot be cast to [Ljava.lang.Class;

at com.atlassian.plugin.event.impl.MethodSelectorListenerHandler$1$1.invoke(MethodSelectorListenerHandler.java:67)

at com.atlassian.event.internal.AsynchronousAbleEventDispatcher$2$1.run(AsynchronousAbleEventDispatcher.java:44)

at com.atlassian.event.internal.AsynchronousAbleEventDispatcher$1.execute(AsynchronousAbleEventDispatcher.java:29)

at com.atlassian.event.internal.AsynchronousAbleEventDispatcher.dispatch(AsynchronousAbleEventDispatcher.java:90)

at com.atlassian.event.internal.EventPublisherImpl.invokeListeners(EventPublisherImpl.java:151)

at com.atlassian.event.internal.EventPublisherImpl.publish(EventPublisherImpl.java:70)

at com.atlassian.plugin.event.impl.DefaultPluginEventManager.broadcast(DefaultPluginEventManager.java:84)

at com.atlassian.plugin.manager.DefaultPluginManager.init(DefaultPluginManager.java:149)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:483)

We just had the same issue with a couple agents (of many) and the common thread was a 1.8 JDK had just been installed on both.  As part of the install process it appears the global PATH variable was modified, and the new JDK was put first in line.

At one point our Bamboo agent's conf/bamboo.conf was pointed to a specific JDK rather than having "wrapper.java.command=java" where it depends on Windows values.  Don't know when that changed, but I just changed it back!


Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Tuesday in Statuspage

Introducing Statuspage Getting Started guides! First up: What is Statuspage?

Over the next several weeks we'll be sharing some of our Getting Started guides here in the community. Throughout this series of posts, we'd love to hear from customers and non-customers ab...

171 views 4 1
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you