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

Deleting an external run does not immediately remove it from build list


      ViewJob.removeRun was implemented to just mark the build list (e.g. for an external monitor job) as "dirty", so that the next time the build list was requested, a reload task would be scheduled, and the next time after that the build would actually disappear. But if you configured the job to use LogRotator then each time that ran, Run.delete after deleting a build directory would ask to remove the build from the list, but the next rotation would still see this ghost build in the list and try to delete it again, which would of course fail with

      ... hudson.model.Run execute
      SEVERE: Failed to rotate log
      java.io.IOException: .../jobs/.../builds/2013-... is in use
      	at hudson.model.Run.delete(Run.java:1264)
      	at hudson.tasks.LogRotator.perform(LogRotator.java:132)
      	at hudson.model.Job.logRotate(Job.java:337)
      	at hudson.model.Run.execute(Run.java:1525)
      	at hudson.model.ExternalRun.acceptRemoteSubmission(ExternalRun.java:104)
      	at hudson.model.ExternalJob.doPostBuildResult(ExternalJob.java:102)

      For a frequently run task, these warnings could fill up the log, though it seems otherwise harmless since all the builds do eventually get deleted.

            jglick Jesse Glick
            jglick Jesse Glick
            0 Vote for this issue
            6 Start watching this issue