Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-17138

Deleting/renaming jobs using external builds directory does not move builds

    XMLWordPrintable

Details

    Description

      If you set the external builds directory for Jenkins to e.g. /tmp/builds/${ITEM_FULL_NAME} and build some job, then rename it, the existing build records will remain in /tmp/builds/oldname/* and be inaccessible. Similarly, if you delete the job, the build records will be left behind, potentially consuming a great deal of disk space.

      Attachments

        Issue Links

          Activity

            jglick Jesse Glick added a comment -

            JENKINS-17137 is a related problem with a different cause. The fix of JENKINS-16457 helps identify the problem loading the old build records in case of a rename.

            jglick Jesse Glick added a comment - JENKINS-17137 is a related problem with a different cause. The fix of JENKINS-16457 helps identify the problem loading the old build records in case of a rename.
            jglick Jesse Glick added a comment -

            Job.renameTo needs to take getBuildDir into account.

            Also the workspace on master should be moved if it exists.

            jglick Jesse Glick added a comment - Job.renameTo needs to take getBuildDir into account. Also the workspace on master should be moved if it exists.
            jglick Jesse Glick added a comment -

            Ideally the workspace would be moved, but this is problematic since the workspace path is encoded in the build record. So for now leaving workspaces alone; they are intended to be disposable anyway (so it is not a problem to periodically wipe out the whole external workspace dir).

            jglick Jesse Glick added a comment - Ideally the workspace would be moved, but this is problematic since the workspace path is encoded in the build record. So for now leaving workspaces alone; they are intended to be disposable anyway (so it is not a problem to periodically wipe out the whole external workspace dir).

            Code changed in jenkins
            User: Jesse Glick
            Path:
            changelog.html
            core/src/main/java/hudson/model/Job.java
            test/src/test/java/hudson/model/AbstractProjectTest.java
            http://jenkins-ci.org/commit/jenkins/d98716dfbad96f566938b90a5a8b50ce9765575b
            Log:
            [FIXED JENKINS-17138] Deleting/renaming jobs using external builds directory does not move builds.


            You received this message because you are subscribed to the Google Groups "Jenkins Commits" group.
            To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-commits+unsubscribe@googlegroups.com.
            For more options, visit https://groups.google.com/groups/opt_out.

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: changelog.html core/src/main/java/hudson/model/Job.java test/src/test/java/hudson/model/AbstractProjectTest.java http://jenkins-ci.org/commit/jenkins/d98716dfbad96f566938b90a5a8b50ce9765575b Log: [FIXED JENKINS-17138] Deleting/renaming jobs using external builds directory does not move builds. – You received this message because you are subscribed to the Google Groups "Jenkins Commits" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-commits+unsubscribe@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out .
            dogfood dogfood added a comment -

            Integrated in jenkins_main_trunk #2358
            [FIXED JENKINS-17138] Deleting/renaming jobs using external builds directory does not move builds. (Revision d98716dfbad96f566938b90a5a8b50ce9765575b)

            Result = SUCCESS
            Jesse Glick : d98716dfbad96f566938b90a5a8b50ce9765575b
            Files :

            • changelog.html
            • test/src/test/java/hudson/model/AbstractProjectTest.java
            • core/src/main/java/hudson/model/Job.java
            dogfood dogfood added a comment - Integrated in jenkins_main_trunk #2358 [FIXED JENKINS-17138] Deleting/renaming jobs using external builds directory does not move builds. (Revision d98716dfbad96f566938b90a5a8b50ce9765575b) Result = SUCCESS Jesse Glick : d98716dfbad96f566938b90a5a8b50ce9765575b Files : changelog.html test/src/test/java/hudson/model/AbstractProjectTest.java core/src/main/java/hudson/model/Job.java

            People

              jglick Jesse Glick
              jglick Jesse Glick
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: