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

A past build Plan re-run will run endlessly if its original Plan structure has been modified

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Medium
    • 8.2.6
    • 8.0.4, 8.2.4
    • Build Queues, Builds
    • None

    Description

      Problem

      Bamboo will put a Build re-run in an "endless run" state and will not follow any stop commands in case the current Build plan has been modified since the original referenced Plan used by the re-run

      Environment

      Bamboo 8.2

      Steps to Reproduce

      1. Create a Build plan with "Stage 1" and two Jobs with a simple "sleep 30"
      2. Run the Build plan once - it will succeed
      3. Modify the Build plan by adding an additional Stage, then move/drag "Job 2" to "Stage 2"
      4. Re-run the Build that had succeeded

      Additional issue:

      When re-running a build Bamboo will follow the current Plan structure to indicate the build order, so if a "Job 1" from "Stage 1" has been moved to "Stage 2", it is expected that Job to be run only when "Stage 2" starts, but that's not the case, within this issue, Bamboo will run "Job 1" and "Stage 2" before "Stage 1" and break the execution order.

      Expected Results

      The re-run should succeed and finish completely

      Actual Results

      The re-run Jobs succeed, but the Build status remains on "Building". Whenever trying to stop it manually we get logs such as:

      2022-07-06 16:39:37,890 INFO [scheduler_Worker-4] [OrphanedBuildMonitorJob] DEF-BREAK-12 marked as InProgress but not present in CBC since Wed Jul 06 16:35:37 AEST 2022
      2022-07-06 16:39:37,891 INFO [scheduler_Worker-4] [OrphanedBuildMonitorJob] Found a job with no running tasks: DEF-BREAK. Trying to stop.
      2022-07-06 16:39:37,893 INFO [scheduler_Worker-4] [OrphanedBuildMonitorJob] Finishing build from OrphanedBuildMonitorJob DEF-BREAK-JOB2-12
      2022-07-06 16:39:37,893 INFO [scheduler_Worker-4] [CurrentlyBuildingContainer] removeCurrentlyBuilding called for [DEF-BREAK-JOB2-12]
      2022-07-06 16:39:37,893 INFO [scheduler_Worker-4] [CurrentlyBuildingContainer] removeCurrentlyBuilding called for [DEF-BREAK-JOB2-12] but the plan did not exist in CBC
      2022-07-06 16:39:37,893 INFO [scheduler_Worker-4] [DefaultBuildExecutionManager] Did not remove DEF-BREAK-JOB2-12 from CBC
      

      Workaround

      Do not re-run any past builds. Instead, run a fresh build of the same plan.

      Attachments

        Issue Links

          Activity

            People

              mgardias Marcin Gardias
              73868399605e Eduardo Alvarenga
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: