Bamboo returns error when shippedWithBamboo has null values

Still need help?

The Atlassian Community is here for you.

Ask the community

Problem

Elastic Bamboo errors are pushed to UI when null values are in shipped_with_bamboo column. 

2015-11-16 16:55:06,471 INFO [localhost-startStop-1] [ElasticImageConfigurationManagerImpl] Checking if stock EC2 images need updating...
2015-11-16 16:55:06,534 INFO [localhost-startStop-1] [DefaultErrorHandler] Recording an error: Null value was assigned to a property of primitive type setter of com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl.shippedWithBamboo; nested exception is org.hibernate.PropertyAccessException: Null value was assigned to a property of primitive type setter of com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl.shippedWithBamboo
2015-11-16 16:55:06,540 ERROR [localhost-startStop-1] [BambooContainer] Unable to update elastic configuration.
org.springframework.orm.hibernate3.HibernateSystemException: Null value was assigned to a property of primitive type setter of com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl.shippedWithBamboo; nested exception is org.hibernate.PropertyAccessException: Null value was assigned to a property of primitive type setter of com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl.shippedWithBamboo

Cause

The root cause of this issue is that the elastic_image  table has a column {{shipped_with_bamboo}} which can only accept an integer value. If that column has a null value, Bamboo pushes the error to Bamboo UI. You can check this by running the command below:

SELECT name,ami_image_id,shipped_with_bamboo FROM elastic_image;

 

Resolution

(warning) Backup database before making any modifications

  1. Stop Bamboo
  2. Run:

    UPDATE elastic_image SET shipped_with_bamboo = 0 WHERE shipped_with_bamboo IS NULL;
  3. Start Bamboo
Last modified on Apr 21, 2016

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.