-
Bug
-
Resolution: Duplicate
-
Low
-
6.4.0
-
Severity 3 - Minor
-
Summary
After renaming the artifact in YAML, deployment environment couldn't deploy anymore and couldn't change the build plan
Steps to Reproduce
- Use the following YAML for a build plan:
--- project: key: SPECS plan: key: STASH name: bamboo specs yaml stages: - jobs: - scripts: - echo 'testing artifact' artifacts: - name: test files path: test.txt ...
- Run the build plan to create the artifact
- Create a deployment project to use download this artifact
- Create/deploy a release from this deployment project
- Edit the YAML file to change the name "test files" to be "test file" (without "s")
- Run the build to create artifact
- Create/deploy a release from the related deployment project
- Change the build plan in the deployment project
Expected Results
- The release successfully created/deployed
- Able to change the build plan
Actual Results
- When creating/deploying the release, the below exception is thrown in the atlassian-bamboo.log file:
2018-03-06 16:08:24,137 ERROR [http-nio-8085-exec-14] [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.GeneratedMethodAccessor1632.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) 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)
- When changing the build plan in the deployment project, the below exception is thrown in the atlassian-bamboo.log file:
2018-03-06 16:09:28,037 ERROR [http-nio-8085-exec-13] [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.GeneratedMethodAccessor1632.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) 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.projects.service.DeploymentProjectServiceImpl.validateArtifactTaskDefinitionOnPlanChange(DeploymentProjectServiceImpl.java:407) ... 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)
Notes
In Deployment Project Summary, the Available artifact is showing "No shared artifacts found for related plan" even though the shared artifact exist.
Workaround
- Delete the YAML build plan
- Change the related Deployment Project to use different build plan (so that Bamboo will be able to fully delete the above build plan)
- Re-create the YAML build plan
- Change the related Deployment Project to use the YAML build plan again
- is duplicated by
-
BAM-19782 Deleting an artifact definition from a build plan will corrupt any linked deployment plans with artifact download tasks
- Closed
- is related to
-
BAM-19948 Deployment project item list not updated when plan artifact is added/modified/removed through specs
- Closed
- mentioned in
-
Page Loading...