Uploaded image for project: 'Bamboo'
  1. Bamboo
  2. BAM-12684

Bamboo git branch automatic deletion

    XMLWordPrintable

    Details

      Description

      When a branch is deleted from the Git repository, and the branch gets triggered to run, Bamboo shows this error before disabling the Bamboo brnach:

      2013-01-28 13:48:28,629 INFO [2-DelayedChangeDetectionThread:pool-5-thread-1] [RetryingTaskExecutor] Task 'Collecting changes for PROJ1-PLAN11' was unsuccessful. Run 2 / 2. Exception thrown when running task 'Collecting changes for PROJ1-PLAN11', with message: Cannot determine head revision of 'file:///Users/akhachatryan/dev/Repositories/GitTest' on branch 'next'. Branch has probably been removed.
      2013-01-28 13:48:28,629 ERROR [2-DelayedChangeDetectionThread:pool-5-thread-1] [RetryingTaskExecutor] Failed to run task 'Collecting changes for PROJ1-PLAN11' after 2 attempts. Task was not executed.
      2013-01-28 13:48:28,629 ERROR [2-DelayedChangeDetectionThread:pool-5-thread-1] [RetryingTaskExecutor] Exception being rethrown
      2013-01-28 13:48:28,630 ERROR [2-DelayedChangeDetectionThread:pool-5-thread-1] [ChainExecutionManagerImpl] Errors getting changes for PROJ1-PLAN11-1
      java.lang.RuntimeException: com.atlassian.bamboo.repository.InvalidRepositoryException: Cannot determine head revision of 'file:///Users/akhachatryan/dev/Repositories/GitTest' on branch 'next'. Branch has probably been removed.
      	at com.atlassian.bamboo.executor.RetryingTaskExecutor.rerun(RetryingTaskExecutor.java:132)
      	at com.atlassian.bamboo.executor.RetryingTaskExecutor.runTask(RetryingTaskExecutor.java:88)
      	at com.atlassian.bamboo.executor.RetryingTaskExecutor.retry(RetryingTaskExecutor.java:191)
      	at com.atlassian.bamboo.executor.RetryingTaskExecutor.retry(RetryingTaskExecutor.java:176)
      	at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectionChangesWithRetry(DefaultChangeDetectionManager.java:457)
      	at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuildInternal(DefaultChangeDetectionManager.java:318)
      	at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceRevisions(DefaultChangeDetectionManager.java:251)
      	at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceRevisions(DefaultChangeDetectionManager.java:161)
      	at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectAllChangesSinceLastBuild(DefaultChangeDetectionManager.java:127)
      	at com.atlassian.bamboo.v2.trigger.ManualBuildDetectionAction.performDelayedChangeDetection(ManualBuildDetectionAction.java:113)
      	at com.atlassian.bamboo.chains.ChainExecutionManagerImpl$2.getChainState(ChainExecutionManagerImpl.java:199)
      	at com.atlassian.bamboo.chains.ChainExecutionManagerImpl.tryStartChainState(ChainExecutionManagerImpl.java:252)
      	at com.atlassian.bamboo.chains.ChainExecutionManagerImpl.delayedStart(ChainExecutionManagerImpl.java:189)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
      	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
      	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
      	at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
      	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
      	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
      	at $Proxy78.delayedStart(Unknown Source)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
      	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:198)
      	at $Proxy79.delayedStart(Unknown Source)
      	at com.atlassian.bamboo.plan.PlanExecutionManagerImpl$1$1$1.call(PlanExecutionManagerImpl.java:300)
      	at com.atlassian.bamboo.plan.PlanExecutionManagerImpl$1$1$1.call(PlanExecutionManagerImpl.java:296)
      	at com.atlassian.util.concurrent.ManagedLocks$ManagedLockImpl.withLock(ManagedLocks.java:324)
      	at com.atlassian.bamboo.plan.PlanExecutionLockServiceImpl.lock(PlanExecutionLockServiceImpl.java:77)
      	at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.doWithProcessLock(PlanExecutionManagerImpl.java:467)
      	at com.atlassian.bamboo.plan.PlanExecutionManagerImpl.access$200(PlanExecutionManagerImpl.java:48)
      	at com.atlassian.bamboo.plan.PlanExecutionManagerImpl$1$1.run(PlanExecutionManagerImpl.java:295)
      	at com.atlassian.bamboo.build.pipeline.concurrent.NamedThreadFactory$2.run(NamedThreadFactory.java:52)
      	at java.lang.Thread.run(Thread.java:680)
      Caused by: com.atlassian.bamboo.repository.InvalidRepositoryException: Cannot determine head revision of 'file:///Users/akhachatryan/dev/Repositories/GitTest' on branch 'next'. Branch has probably been removed.
      	at com.atlassian.bamboo.plugins.git.NativeGitOperationHelper.obtainLatestRevision(NativeGitOperationHelper.java:508)
      	at com.atlassian.bamboo.plugins.git.GitRepository.collectChangesSinceLastBuild(GitRepository.java:223)
      	at com.atlassian.bamboo.plugins.git.GitRepository.collectChangesSinceLastBuild(GitRepository.java:211)
      	at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager$1.call(DefaultChangeDetectionManager.java:461)
      	at com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager$1.call(DefaultChangeDetectionManager.java:458)
      	at com.atlassian.bamboo.executor.RetryingTaskExecutor.rerun(RetryingTaskExecutor.java:108)
      	... 39 more
      

      Please handle this exception more gracefully.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              akhachatryan ArmenA
              Votes:
              32 Vote for this issue
              Watchers:
              23 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: