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

Bamboo fails to download shared artifact (in deployment) from Specs plan

      Summary

      Bamboo fails to download shared artifact (in deployment) from Specs plan

      Environment

      Bamboo 6.4

      Steps to Reproduce

      1. Create plan that generates an artifact.
      2. Configure the artifact to be shared, and empty (default) location.
      3. Create a deployment project using this plan.
      4. Create an "Artifact download task" for this artifact.
        (optional: Build and deploy)
      5. Export the build plan as Specs.
      6. Run Specs (no need to do any changes in the code).
      7. Build.
      8. Create release from that build.
        (alternative: Got to deployment project, deploy, choose "Create new release from build result")

      Expected Results

      Release is created.

      Actual Results

      Bamboo fails with the following Internal Server Error

      2018-03-16 10:33:09,254 INFO [http-nio-8085-exec-18] [AccessLogFilter] mate POST http://bamboo642:8085/deploy/doCreateDeploymentVersion.action 545046kb
      2018-03-16 10:33:09,372 ERROR [http-nio-8085-exec-18] [ExceptionMappingInterceptor] Cannot instantiate abstract class or interface:  : com.atlassian.bamboo.deployments.projects.persistence.items.AbstractMutableDeploymentProjectItem; nested exception is org.hibernate.InstantiationException: Cannot instantiate abstract class or interface:  : com.atlassian.bamboo.deployments.projects.persistence.items.AbstractMutableDeploymentProjectItem
      org.springframework.orm.hibernate5.HibernateSystemException: Cannot instantiate abstract class or interface:  : com.atlassian.bamboo.deployments.projects.persistence.items.AbstractMutableDeploymentProjectItem; nested exception is org.hibernate.InstantiationException: Cannot instantiate abstract class or interface:  : com.atlassian.bamboo.deployments.projects.persistence.items.AbstractMutableDeploymentProjectItem
      	at org.springframework.orm.hibernate5.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:296)
      	at org.springframework.orm.hibernate5.HibernateTemplate.doExecute(HibernateTemplate.java:362)
      	at org.springframework.orm.hibernate5.HibernateTemplate.execute(HibernateTemplate.java:313)
      	at com.atlassian.bamboo.deployments.projects.persistence.DeploymentProjectDaoImpl.getProjectItems(DeploymentProjectDaoImpl.java:206)
      	at sun.reflect.GeneratedMethodAccessor2370.invoke(Unknown Source)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:498)
      	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:333)
      	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
      	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
      	at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
      	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:282)
      	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
      	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
      	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
      	at com.sun.proxy.$Proxy89.getProjectItems(Unknown Source)
      	at com.atlassian.bamboo.deployments.versions.service.DeploymentVersionServiceImpl$3.run(DeploymentVersionServiceImpl.java:454)
      (...)
      Caused by: org.hibernate.InstantiationException: Cannot instantiate abstract class or interface:  : com.atlassian.bamboo.deployments.projects.persistence.items.AbstractMutableDeploymentProjectItem
      	at org.hibernate.tuple.PojoInstantiator.instantiate(PojoInstantiator.java:79)
      	at org.hibernate.tuple.PojoInstantiator.instantiate(PojoInstantiator.java:105)
      	at org.hibernate.tuple.entity.AbstractEntityTuplizer.instantiate(AbstractEntityTuplizer.java:733)
      	at org.hibernate.persister.entity.AbstractEntityPersister.instantiate(AbstractEntityPersister.java:4740)
      	at org.hibernate.internal.SessionImpl.instantiate(SessionImpl.java:1624)
      	at org.hibernate.internal.SessionImpl.instantiate(SessionImpl.java:1608)
      	at org.hibernate.loader.Loader.instanceNotYetLoaded(Loader.java:1658)
      	at org.hibernate.loader.Loader.getRow(Loader.java:1556)
      	at org.hibernate.loader.Loader.getRowFromResultSet(Loader.java:740)
      	at org.hibernate.loader.Loader.processResultSet(Loader.java:985)
      	at org.hibernate.loader.Loader.doQuery(Loader.java:943)
      	at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:349)
      	at org.hibernate.loader.Loader.doList(Loader.java:2615)
      	at org.hibernate.loader.Loader.doList(Loader.java:2598)
      	at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2430)
      	at org.hibernate.loader.Loader.list(Loader.java:2425)
      	at org.hibernate.loader.criteria.CriteriaLoader.list(CriteriaLoader.java:109)
      	at org.hibernate.internal.SessionImpl.list(SessionImpl.java:1896)
      	at org.hibernate.internal.CriteriaImpl.list(CriteriaImpl.java:366)
      	at com.atlassian.bamboo.deployments.projects.persistence.DeploymentProjectDaoImpl.lambda$getProjectItems$10(DeploymentProjectDaoImpl.java:210)
      	at org.springframework.orm.hibernate5.HibernateTemplate.doExecute(HibernateTemplate.java:359)
      	... 293 more
      

            [BAM-19770] Bamboo fails to download shared artifact (in deployment) from Specs plan

            Tuyn Doan added a comment -

            So, I want ask bamboo 6.4.2 release date time? 

            Thanks 

            Tuyn Doan added a comment - So, I want ask bamboo 6.4.2 release date time?  Thanks 

            We just came across the same issue on version 6.3 .

            In our case the issue is affecting production releases planned for upcoming week and might be having severe impact.

            Our logs didn't reveal exactly the same stack trace, but I'm adding one with ExceptionMappingInterceptor context.

            Karel Mladý added a comment - We just came across the same issue on version 6.3 . In our case the issue is affecting production releases planned for upcoming week and might be having severe impact. Our logs didn't reveal exactly the same stack trace, but I'm adding one with ExceptionMappingInterceptor context.

            I was asked to provide the use case which exposed this issue, so here it is:

            Over a period of 3-4 years I developed 50+ build and deploy plans which basically follow the same steps but have diverged in wording used to describe tasks, the notifications sent at various times, the permissions granted in various environments and other minor anomalies.

            I am in the processes of turning over these plans to another group, and I wanted all plans to be consistent.

            Recently I made a change in some of our scripted tasks which required all plans to provide NEW shared artifacts, along with the currently existing shared artifacts.

            I reconfigured one plan to be the model for all other plans. As explained in the support request, I copied the bamboo plan specs for that plan.  I parameterized the java file with place holders for the changing information (repositories, plan names, etc.).  I then created an input file with the correct values for each plan and created a script the would re-create each plan in bamboo based on the template.

            When looking at the plan after the run everything looked fine.  But as stated in the support request, the Release would not picked up shared artifacts whose definition was "re-created" by the run.

            Bottom line:

            I was using Bamboo Plan Specs to create a template plan that would be used to update 50 other plans.

             

            Steve Silverman added a comment - I was asked to provide the use case which exposed this issue, so here it is: Over a period of 3-4 years I developed 50+ build and deploy plans which basically follow the same steps but have diverged in wording used to describe tasks, the notifications sent at various times, the permissions granted in various environments and other minor anomalies. I am in the processes of turning over these plans to another group, and I wanted all plans to be consistent. Recently I made a change in some of our scripted tasks which required all plans to provide NEW shared artifacts, along with the currently existing shared artifacts. I reconfigured one plan to be the model for all other plans. As explained in the support request, I copied the bamboo plan specs for that plan.  I parameterized the java file with place holders for the changing information (repositories, plan names, etc.).  I then created an input file with the correct values for each plan and created a script the would re-create each plan in bamboo based on the template. When looking at the plan after the run everything looked fine.  But as stated in the support request, the Release would not picked up shared artifacts whose definition was "re-created" by the run. Bottom line: I was using Bamboo Plan Specs to create a template plan that would be used to update 50 other plans.  

              Unassigned Unassigned
              pdemitrio Patricio
              Affected customers:
              4 This affects my team
              Watchers:
              10 Start watching this issue

                Created:
                Updated:
                Resolved: