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

Bamboo doesn't check Java version on startup for a fresh install

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Low Low
    • 7.0.0, 6.10.5
    • 6.10.2, 6.10.4
    • Setup Wizard
    • None

      Issue Summary

      Since Bamboo 6.10.2, the Java version is validated against unsupported versions. However, this doesn't work on a fresh install as validation tasks aren't run until after the setup wizard but unsupported Java versions will cause issues preventing you to get to that phase.

      Steps to Reproduce

      1. Install Java 11 (unsupported)
      2. Start a fresh Bamboo instance with MySQL and try to progress through the setup wizard

      Expected Results

      Bamboo Java version validation reports an error before even getting to the setup wizard

      Actual Results

      Setup wizard is presented however unsupported Java version causes issues progressing through the database setup.

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

      2019-12-13 08:07:28,393 ERROR [http-nio-8085-exec-10] [DefaultDispatcherErrorHandler] Exception occurred during processing request: Unable to instantiate Action, com.atlassian.bamboo.ww2.actions.setup.SetupDatabaseConnectionAction,  defined for 'performSetupDatabaseConnection' in namespace '/setup'Error creating bean with name 'reloadableBeanFactories' defined in class path resource [applicationContextPlugin.xml]: BeanPostProcessor before instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.transaction.config.internalTransactionAdvisor': Cannot resolve reference to bean 'org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0' while setting bean property 'transactionAttributeSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0': BeanPostProcessor before instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'customBuildCompleteActionAdvisor' defined in class path resource [applicationContextManagers.xml]: Cannot resolve reference to bean 'hibernateInterceptor' while setting bean property 'advice'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateInterceptor' defined in class path resource [applicationContextPersistence.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [applicationContextPersistence.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException
      Unable to instantiate Action, com.atlassian.bamboo.ww2.actions.setup.SetupDatabaseConnectionAction,  defined for 'performSetupDatabaseConnection' in namespace '/setup'Error creating bean with name 'reloadableBeanFactories' defined in class path resource [applicationContextPlugin.xml]: BeanPostProcessor before instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.transaction.config.internalTransactionAdvisor': Cannot resolve reference to bean 'org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0' while setting bean property 'transactionAttributeSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0': BeanPostProcessor before instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'customBuildCompleteActionAdvisor' defined in class path resource [applicationContextManagers.xml]: Cannot resolve reference to bean 'hibernateInterceptor' while setting bean property 'advice'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateInterceptor' defined in class path resource [applicationContextPersistence.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [applicationContextPersistence.xml]: Invocation of init method failed; nested exception is java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException - action - file:/sandbox-local/bamboo/data/www/bamboo/atlassian-bamboo-6.10.4/atlassian-bamboo/WEB-INF/classes/struts.xml:505:128
      	at com.opensymphony.xwork2.DefaultActionInvocation.createAction(DefaultActionInvocation.java:320)
      	at com.opensymphony.xwork2.DefaultActionInvocation.init(DefaultActionInvocation.java:401)
      	at com.opensymphony.xwork2.DefaultActionProxy.prepare(DefaultActionProxy.java:201)
      	at org.apache.struts2.factory.StrutsActionProxy.prepare(StrutsActionProxy.java:57)
      	at org.apache.struts2.factory.StrutsActionProxyFactory.createActionProxy(StrutsActionProxyFactory.java:32)
      ....
      Caused by: java.lang.ClassNotFoundException: javax.xml.bind.JAXBException
      	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1364)
      	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1185)
      	... 99 more
      

      Workaround

      Currently there is no known workaround for this behavior. A workaround will be added here when available

            [BAM-20743] Bamboo doesn't check Java version on startup for a fresh install

            Anik Sengupta made changes -
            Affects Version/s New: 6.10.4 [ 89690 ]
            Ellie Z (they/them) made changes -
            Remote Link New: This issue links to "Page (Confluence)" [ 471706 ]
            Ellie Z (they/them) made changes -
            Resolution New: Fixed [ 1 ]
            Status Original: Waiting for Release [ 12075 ] New: Closed [ 6 ]
            Ellie Z (they/them) made changes -
            Remote Link New: This issue links to "Page (Confluence)" [ 464541 ]
            Ellie Z (they/them) made changes -
            Status Original: In Progress [ 3 ] New: Waiting for Release [ 12075 ]
            Ellie Z (they/them) made changes -
            Fix Version/s New: 7.0.0 [ 89610 ]
            Fix Version/s New: 6.10.5 [ 90700 ]
            Pawel Skierczynski made changes -
            Assignee New: Ellie Z (they/them) [ ezeidan ]
            Pawel Skierczynski made changes -
            Status Original: Short Term Backlog [ 12074 ] New: In Progress [ 3 ]
            Pawel Skierczynski made changes -
            Status Original: Needs Triage [ 10030 ] New: Short Term Backlog [ 12074 ]
            Ellie Z (they/them) made changes -
            Remote Link New: This issue links to "+core+ Dogfooding › Test Git Branch Detection › feature-BAM-20743-check-java-version-on-startup (tardigrade-bamboo)" [ 463730 ]

              ezeidan Ellie Z (they/them)
              jowen@atlassian.com Jeremy Owen
              Affected customers:
              0 This affects my team
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: