Uploaded image for project: 'Bamboo Data Center'
  1. Bamboo Data Center
  2. BAM-20008

Scheduled Elastic Instance startup fails with Hibernate error

      Summary

      Elastic Image crons, created in the "Image Schedule" UI fail to trigger Elastic Image startup

      Steps to Reproduce

      1. Configure Elastic Bamboo
      2. Configure an Elastic Image Schedule
      3. Let it run

      Expected Results

      Instance Starts at scheduled time

      Actual Results

      The below exception is thrown in the atlassian-bamboo.log file:

      2018-07-26 17:50:00,113 INFO [scheduler_Worker-1] [ElasticFunctionalityFacadeImpl] Adjusting elastic agents with schedule: com.atlassian.bamboo.agent.elastic.schedule.ElasticInstanceScheduleImpl@5429cf[48758785,0 50 17 ? * *,com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl@810e8617,EQUALS,1,true]
      2018-07-26 17:50:00,113 INFO [scheduler_Worker-1] [ElasticFunctionalityFacadeImpl] Starting up 1 of 'Ubuntu stock image' elastic instances
      2018-07-26 17:50:00,123 ERROR [scheduler_Worker-1] [JobRunShell] Job ElasticInstanceSchedule.ElasticInstanceScheduleJob threw an unhandled Exception:
      org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl.startupScripts, could not initialize proxy - no Session
      ...
      2018-07-26 17:50:00,178 ERROR [scheduler_Worker-1] [ErrorLogger] Job (ElasticInstanceSchedule.ElasticInstanceScheduleJob threw an exception.
      org.quartz.SchedulerException: Job threw an unhandled exception. [See nested exception: org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl.startupScripts, could not initialize proxy - no Session]
      ....
      Caused by: org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.atlassian.bamboo.agent.elastic.server.ElasticImageConfigurationImpl.startupScripts, could not initialize proxy - no Session
      ...
      

      Workaround

      There is no known workaround for this. Instances will need to be manually started.

              Unassigned Unassigned
              ezeidan Ellie Z (they/them)
              Affected customers:
              16 This affects my team
              Watchers:
              8 Start watching this issue

                Created:
                Updated:
                Resolved: