If something goes wrong during a particular folder recomputation run—for example, causing many children to be orphaned when they should not have been—it is not possible to diagnose this after the fact if a correct run intervened, since only the latest log is saved.

      Without getting into the more complex machinery of RunList, it should be possible to save at least a reasonable selection of recent logs for diagnostic purposes. In particular any run which orphaned a child ought to be saved for a while, as should any run which terminated with an exception.

      Whether these historical logs need to be displayed in the UI, or merely saved to disk, is another question. For the short term it is simpler to avoid UI changes.

          [JENKINS-33817] Save more than one folder recomputation log

          Jesse Glick created issue -
          Jesse Glick made changes -
          Labels Original: diagnostics New: diagnostics multibranch
          Jesse Glick made changes -
          Remote Link New: This issue links to "PR 50 (Web Link)" [ 14126 ]
          Jesse Glick made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]

          Code changed in jenkins
          User: Jesse Glick
          Path:
          src/main/java/com/cloudbees/hudson/plugins/folder/computed/FolderComputation.java
          http://jenkins-ci.org/commit/cloudbees-folder-plugin/355600a4c7232c1b28fefe71a7c8dcb6d5fdc640
          Log:
          [FIXED JENKINS-33817] Option to save backup copies of computation log.
          Pass -Dcom.cloudbees.hudson.plugins.folder.computed.FolderComputation.BACKUP_LOG_COUNT=5
          to save computation.log.1–computation.log.5 as backups.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: src/main/java/com/cloudbees/hudson/plugins/folder/computed/FolderComputation.java http://jenkins-ci.org/commit/cloudbees-folder-plugin/355600a4c7232c1b28fefe71a7c8dcb6d5fdc640 Log: [FIXED JENKINS-33817] Option to save backup copies of computation log. Pass -Dcom.cloudbees.hudson.plugins.folder.computed.FolderComputation.BACKUP_LOG_COUNT=5 to save computation.log.1–computation.log.5 as backups.
          SCM/JIRA link daemon made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: In Progress [ 3 ] New: Resolved [ 5 ]

          Code changed in jenkins
          User: Jesse Glick
          Path:
          src/main/java/com/cloudbees/hudson/plugins/folder/computed/FolderComputation.java
          http://jenkins-ci.org/commit/cloudbees-folder-plugin/040ba1a5103230abe9fe61db1e11148bc00d4cb9
          Log:
          Merge pull request #50 from jglick/backup-logs-JENKINS-33817

          JENKINS-33817 Option to save backup copies of computation log

          Compare: https://github.com/jenkinsci/cloudbees-folder-plugin/compare/b8a4fd6685f6...040ba1a51032

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: src/main/java/com/cloudbees/hudson/plugins/folder/computed/FolderComputation.java http://jenkins-ci.org/commit/cloudbees-folder-plugin/040ba1a5103230abe9fe61db1e11148bc00d4cb9 Log: Merge pull request #50 from jglick/backup-logs- JENKINS-33817 JENKINS-33817 Option to save backup copies of computation log Compare: https://github.com/jenkinsci/cloudbees-folder-plugin/compare/b8a4fd6685f6...040ba1a51032
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 169811 ] New: JNJira + In-Review [ 198699 ]

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

              Created:
              Updated:
              Resolved: