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

Bamboo is deleting active plans under project where marked_for_deletion as set as true for Projects

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Low Low
    • 11.0.0, 10.2.2, 9.6.11
    • 9.6.4
    • Expiry
    • None

      Issue Summary

      Currently in Bamboo it is not possible to delete a project from the Bamboo GUI until all the plans under it are deleted. So in an ideal scenario it is not possible to have marked_for_deletion for projects is set as True if there are active plans under the project.

      Let's assume for some unknown reason if marked_for_deletion for a project is set as True and the project has active plans under it, from Bamboo ( 9.x.x) Bamboo will delete the project and the plans without any checks.

      In Bamboo ( 8.x.x ) this check was present and the below error would be seen in the logs

      2025-02-04 13:07:43,003 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting 1 Project(s) marked for deletion
      2025-02-04 13:07:43,004 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting BAM
      2025-02-04 13:07:43,177 ERROR [DelayedDeletionThread] [DeletionServiceHelper] Project BAM (BAM) contains plans. Delete the plans first.
      java.lang.IllegalArgumentException: Project BAM (BAM) contains plans. Delete the plans first.
              at com.google.common.base.Preconditions.checkArgument(Preconditions.java:43
      

      Steps to Reproduce

      1) Set marked_for_deletion column as true inside Project table for a project which has active plans under it
      2) Wait for the Background deletion service to run.

      Expected Results

      Warning as per the above should be thrown in the logs

      Actual Results

      The active plans gets deleted.

      Workaround

      None as of now.

            [BAM-26024] Bamboo is deleting active plans under project where marked_for_deletion as set as true for Projects

            Alexey Chystoprudov made changes -
            Resolution New: Fixed [ 1 ]
            Status Original: Waiting for Release [ 12075 ] New: Closed [ 6 ]
            Mateusz Szmal made changes -
            Status Original: In Progress [ 3 ] New: Waiting for Release [ 12075 ]
            Mateusz Szmal made changes -
            Fix Version/s New: 9.6.11 [ 110912 ]
            Fix Version/s New: 10.2.2 [ 110830 ]
            Fix Version/s New: 11.0.0 [ 110791 ]
            Mateusz Szmal made changes -
            Assignee New: Mateusz Szmal [ 851f15845f55 ]
            Mateusz Szmal made changes -
            Status Original: Needs Triage [ 10030 ] New: In Progress [ 3 ]
            Mateusz Szmal made changes -
            Remote Link New: This issue links to "+core+ Dogfooding › TBD Test Git Branch Detection › issue-BAM-26024-do-not-remove-active-plans-when-removing-project (tardigrade-bamboo)" [ 989204 ]
            Jonathan Barth made changes -
            Remote Link New: This issue links to "Page (Confluence)" [ 988011 ]
            SET Analytics Bot made changes -
            Support reference count New: 1
            Shashank Kumar made changes -
            Description Original: h3. Issue Summary

            Currently in Bamboo it is not possible to delete a project from the Bamboo GUI until all the plans under it are deleted. So in an ideal scenario it is not possible to have *marked_for_deletion* for *projects* is set as True.

            Let's assume for some unknown reason if *marked_for_deletion* for a *project* is set as True and the project has active plans under it, from Bamboo ( 9.x.x) Bamboo will delete the project and the plans without any checks.

            In Bamboo ( 8.x.x ) this check was present and the below error would be seen in the logs
            {code:java}
            2025-02-04 13:07:43,003 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting 1 Project(s) marked for deletion
            2025-02-04 13:07:43,004 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting BAM
            2025-02-04 13:07:43,177 ERROR [DelayedDeletionThread] [DeletionServiceHelper] Project BAM (BAM) contains plans. Delete the plans first.
            java.lang.IllegalArgumentException: Project BAM (BAM) contains plans. Delete the plans first.
                    at com.google.common.base.Preconditions.checkArgument(Preconditions.java:43
            {code}
            h3. Steps to Reproduce

            1) Set marked_for_deletion column as true inside Project table for a project which has active plans under it
            2) Wait for the Background deletion service to run.
            h3. Expected Results

            Warning as per the above should be thrown in the logs
            h3. Actual Results

            The active plans gets deleted.
            h3. Workaround

            None as of now.
            New: h3. Issue Summary

            Currently in Bamboo it is not possible to delete a project from the Bamboo GUI until all the plans under it are deleted. So in an ideal scenario it is not possible to have *marked_for_deletion* for *projects* is set as True if there are active plans under the project.

            Let's assume for some unknown reason if *marked_for_deletion* for a *project* is set as True and the project has active plans under it, from Bamboo ( 9.x.x) Bamboo will delete the project and the plans without any checks.

            In Bamboo ( 8.x.x ) this check was present and the below error would be seen in the logs
            {code:java}
            2025-02-04 13:07:43,003 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting 1 Project(s) marked for deletion
            2025-02-04 13:07:43,004 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting BAM
            2025-02-04 13:07:43,177 ERROR [DelayedDeletionThread] [DeletionServiceHelper] Project BAM (BAM) contains plans. Delete the plans first.
            java.lang.IllegalArgumentException: Project BAM (BAM) contains plans. Delete the plans first.
                    at com.google.common.base.Preconditions.checkArgument(Preconditions.java:43
            {code}
            h3. Steps to Reproduce

            1) Set marked_for_deletion column as true inside Project table for a project which has active plans under it
            2) Wait for the Background deletion service to run.
            h3. Expected Results

            Warning as per the above should be thrown in the logs
            h3. Actual Results

            The active plans gets deleted.
            h3. Workaround

            None as of now.
            Shashank Kumar made changes -
            Description Original: h3. Issue Summary

            Currently in Bamboo it is not possible to delete a project from the Bamboo GUI until all the plans under it are deleted.

            Let's assume for some unknown reason if *marked_for_deletion* for a *project* is set as True and the project has active plans under it, from Bamboo ( 9.x.x) Bamboo will delete the project and the plans without any checks.

            In Bamboo ( 8.x.x ) this check was present and the below error would be seen in the logs
            {code:java}
            2025-02-04 13:07:43,003 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting 1 Project(s) marked for deletion
            2025-02-04 13:07:43,004 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting BAM
            2025-02-04 13:07:43,177 ERROR [DelayedDeletionThread] [DeletionServiceHelper] Project BAM (BAM) contains plans. Delete the plans first.
            java.lang.IllegalArgumentException: Project BAM (BAM) contains plans. Delete the plans first.
                    at com.google.common.base.Preconditions.checkArgument(Preconditions.java:43
            {code}
             
            h3. Steps to Reproduce

            1) Set marked_for_deletion column as true inside Project table for a project which has active plans under it
            2) Wait for the Background deletion service to run.
            h3. Expected Results

            ghfgh
            h3. Actual Results

            results
            h3. Workaround

            None
            New: h3. Issue Summary

            Currently in Bamboo it is not possible to delete a project from the Bamboo GUI until all the plans under it are deleted. So in an ideal scenario it is not possible to have *marked_for_deletion* for *projects* is set as True.

            Let's assume for some unknown reason if *marked_for_deletion* for a *project* is set as True and the project has active plans under it, from Bamboo ( 9.x.x) Bamboo will delete the project and the plans without any checks.

            In Bamboo ( 8.x.x ) this check was present and the below error would be seen in the logs
            {code:java}
            2025-02-04 13:07:43,003 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting 1 Project(s) marked for deletion
            2025-02-04 13:07:43,004 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting BAM
            2025-02-04 13:07:43,177 ERROR [DelayedDeletionThread] [DeletionServiceHelper] Project BAM (BAM) contains plans. Delete the plans first.
            java.lang.IllegalArgumentException: Project BAM (BAM) contains plans. Delete the plans first.
                    at com.google.common.base.Preconditions.checkArgument(Preconditions.java:43
            {code}
            h3. Steps to Reproduce

            1) Set marked_for_deletion column as true inside Project table for a project which has active plans under it
            2) Wait for the Background deletion service to run.
            h3. Expected Results

            Warning as per the above should be thrown in the logs
            h3. Actual Results

            The active plans gets deleted.
            h3. Workaround

            None as of now.
            Shashank Kumar created issue -

              851f15845f55 Mateusz Szmal
              4f38d6bf51c0 Shashank Kumar
              Affected customers:
              0 This affects my team
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: