com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists.

Atlassian JIRA | Rafael Sperafico [Atlassian] | 2 years ago
  1. 0

    h6. To reproduce the issue # Create a linked repository # Create a Deployment Plan and add an Environment "ENV1" ## Add a "{{Source Code Checkout}}" task and use the linked repository above created. # Run your deployment. # Clone the Environment "ENV1" by naming it as "ENV2" # Run the "ENV2" deployment by promoting the same release or generating a new one. The following message comes up: !bamboo560.noRepositoryExists.png|thumbnail! h6. Stacktrace {code} ... 2014-08-13 15:52:24,659 INFO [10-BAM::Default Agent::Agent:pool-25-thread-1] [DefaultErrorHandler] Recording an error: Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' : 917505-983042 : Job has task that uses source control but no repositories exists. 2014-08-13 15:52:24,659 WARN [10-BAM::Default Agent::Agent:pool-25-thread-1] [BuildAgentControllerImpl] Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists. at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:70) at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:51) at com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129) at com.atlassian.bamboo.v2.build.task.CheckoutDirectoriesSnapshotHelper.<init>(CheckoutDirectoriesSnapshotHelper.java:124) at com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareWorkingDirectory(InitializeBuild.java:101) at com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:82) at com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:53) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:188) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:112) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:110) at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49) at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31) at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20) at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52) at java.lang.Thread.run(Thread.java:744) ... {code} h6. Workaround suggested # Edit you environment "ENV2" tasks and hit the "{{Save}}" button under the "{{Source Code Checkout}}" task.

    Atlassian JIRA | 2 years ago | Rafael Sperafico [Atlassian]
    com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists.
  2. 0

    h6. To reproduce the issue # Create a linked repository # Create a Deployment Plan and add an Environment "ENV1" ## Add a "{{Source Code Checkout}}" task and use the linked repository above created. # Run your deployment. # Clone the Environment "ENV1" by naming it as "ENV2" # Run the "ENV2" deployment by promoting the same release or generating a new one. The following message comes up: !bamboo560.noRepositoryExists.png|thumbnail! h6. Stacktrace {code} ... 2014-08-13 15:52:24,659 INFO [10-BAM::Default Agent::Agent:pool-25-thread-1] [DefaultErrorHandler] Recording an error: Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' : 917505-983042 : Job has task that uses source control but no repositories exists. 2014-08-13 15:52:24,659 WARN [10-BAM::Default Agent::Agent:pool-25-thread-1] [BuildAgentControllerImpl] Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists. at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:70) at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:51) at com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129) at com.atlassian.bamboo.v2.build.task.CheckoutDirectoriesSnapshotHelper.<init>(CheckoutDirectoriesSnapshotHelper.java:124) at com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareWorkingDirectory(InitializeBuild.java:101) at com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:82) at com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:53) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:188) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:112) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:110) at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49) at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31) at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20) at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52) at java.lang.Thread.run(Thread.java:744) ... {code} h6. Workaround suggested # Edit you environment "ENV2" tasks and hit the "{{Save}}" button under the "{{Source Code Checkout}}" task.

    Atlassian JIRA | 2 years ago | Rafael Sperafico [Atlassian]
    com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists.
  3. 0

    We've cloned a few jobs across plans where the job uses the default plan repository. When we attempt to use the job in the new plan, we get something along the lines of: {noformat} com.atlassian.bamboo.repository.RepositoryDefinitionException: Task failed since repository with id 123456789 does not exist. It may have been deleted, please update the task and pick a new repository at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:84) at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:48) at com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129) at com.atlassian.bamboo.v2.build.task.InitializeBuild$CheckoutDirectoriesSnapshotHelper.<init>(InitializeBuild.java:221) at com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareCheckoutDirectories(InitializeBuild.java:128) at com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:110) at com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:77) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:202) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:103) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:109) at com.atlassian.bamboo.build.pipeline.concurrent.NamedThreadFactory$2.run(NamedThreadFactory.java:50) at java.lang.Thread.run(Thread.java:662) {noformat} When cloning jobs across plans where the jobs use the plan default repo there should be one of the following done: # The user is prompted to select a repo from the destination plan as a replacement for the default repo from the original # The repository is reset automatically when the job is created in the destination plan

    Atlassian JIRA | 5 years ago | David Corley
    com.atlassian.bamboo.repository.RepositoryDefinitionException: Task failed since repository with id 123456789 does not exist. It may have been deleted, please update the task and pick a new repository
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    We've cloned a few jobs across plans where the job uses the default plan repository. When we attempt to use the job in the new plan, we get something along the lines of: {noformat} com.atlassian.bamboo.repository.RepositoryDefinitionException: Task failed since repository with id 123456789 does not exist. It may have been deleted, please update the task and pick a new repository at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:84) at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:48) at com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129) at com.atlassian.bamboo.v2.build.task.InitializeBuild$CheckoutDirectoriesSnapshotHelper.<init>(InitializeBuild.java:221) at com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareCheckoutDirectories(InitializeBuild.java:128) at com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:110) at com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:77) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:202) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:103) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:109) at com.atlassian.bamboo.build.pipeline.concurrent.NamedThreadFactory$2.run(NamedThreadFactory.java:50) at java.lang.Thread.run(Thread.java:662) {noformat} When cloning jobs across plans where the jobs use the plan default repo there should be one of the following done: # The user is prompted to select a repo from the destination plan as a replacement for the default repo from the original # The repository is reset automatically when the job is created in the destination plan

    Atlassian JIRA | 5 years ago | David Corley
    com.atlassian.bamboo.repository.RepositoryDefinitionException: Task failed since repository with id 123456789 does not exist. It may have been deleted, please update the task and pick a new repository

    Root Cause Analysis

    1. com.atlassian.bamboo.repository.RepositoryDefinitionException

      Job has task that uses source control but no repositories exists.

      at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply()
    2. com.atlassian.bamboo
      ImpersonationHelper$1.run
      1. com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:70)
      2. com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:51)
      3. com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129)
      4. com.atlassian.bamboo.v2.build.task.CheckoutDirectoriesSnapshotHelper.<init>(CheckoutDirectoriesSnapshotHelper.java:124)
      5. com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareWorkingDirectory(InitializeBuild.java:101)
      6. com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:82)
      7. com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:53)
      8. com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:188)
      9. com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:112)
      10. com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:110)
      11. com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49)
      12. com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31)
      13. com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20)
      14. com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52)
      14 frames
    3. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:744)
      1 frame