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

disableResume does not prevent builds from being resumed

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • workflow-cps-plugin

      Unfortunately, the issue is not 100% reproducible but here is a scenario in which I've seen it happening.

      1. Create a long running (up to an hour) pipeline job.
      2. Set disableResume on the job.
      3. Initiate a build.
      4. Restart the Jenkins container (high memory/CPU pressure might be a factor here as well).
      5. There is a chance the build is trying to resume with the following indication:

      Failing build: shutting down master and build is marked to not resume 
      Resuming build at Wed Sep 23 19:14:28 UTC 2020 after Jenkins restart

      Such builds are also stuck. They do not produce any more output and cannot be killed via UI. They can only be aborted via Script Console. 

       

          [JENKINS-63821] disableResume does not prevent builds from being resumed

          Oleg Nenashev added a comment -

          What is the job type? Jenkins Pipeline?

          Oleg Nenashev added a comment - What is the job type? Jenkins Pipeline?

          Piotr Galar added a comment -

          Yes, it affects Jenkins Pipeline type of jobs. 

          Piotr Galar added a comment - Yes, it affects Jenkins Pipeline type of jobs. 

          Oleg Nenashev added a comment -

          Oleg Nenashev added a comment - CC dnusbaum   bitwiseman  

          Fairly reproducible in my case. Any update on this oleg_nenashev 

          Resume disabled by user, switching to high-performance, low-durability mode
          ...
          Resuming build at Mon Jun 13 11:32:20 EDT 2022 after Jenkins restart

          Matthew Imtiaz added a comment - Fairly reproducible in my case. Any update on this oleg_nenashev   Resume disabled by user, switching to high-performance, low-durability mode ... Resuming build at Mon Jun 13 11:32:20 EDT 2022 after Jenkins restart

          Benjamin added a comment - - edited

          Same issue here

          To reproduce, after a job is complete (success or failure), restart the jenkins.
          The job will resume even though is complete then fail 

          [src] $ /usr/lib/node_modules/allure-commandline/bin/allure generate /home/ec2-user/workspace/Automation-Stylezone-Manual/src/browzwear-tests/allure-results -c -o /home/ec2-user/workspace/Automation-Stylezone-Manual/src/allure-report
          Report successfully generated to /home/ec2-user/workspace/Automation-Stylezone-Manual/src/allure-report
          Allure report was successfully generated.
          Creating artifact for the build.
          Artifact was added to the build.
          [Pipeline] }
          [Pipeline] // stage
          [Pipeline] }
          [Pipeline] // dir
          [Pipeline] }
          [Pipeline] // node
          [Pipeline] }
          [Pipeline] // throttle
          [Pipeline] End of Pipeline
          Finished: SUCCESS
          Resuming build at Wed Oct 26 06:20:19 UTC 2022 after Jenkins restart
          [Pipeline] End of Pipeline
          java.io.FileNotFoundException: /var/lib/jenkins/jobs/Automation-Stylezone-Manual/builds/3/program.dat (No such file or directory)
          	at java.base/java.io.FileInputStream.open0(Native Method)
          	at java.base/java.io.FileInputStream.open(FileInputStream.java:216)
          
           

           

          Benjamin added a comment - - edited Same issue here To reproduce, after a job is complete (success or failure), restart the jenkins. The job will resume even though is complete then fail  [src] $ /usr/lib/node_modules/allure-commandline/bin/allure generate /home/ec2-user/workspace/Automation-Stylezone-Manual/src/browzwear-tests/allure-results -c -o /home/ec2-user/workspace/Automation-Stylezone-Manual/src/allure-report Report successfully generated to /home/ec2-user/workspace/Automation-Stylezone-Manual/src/allure-report Allure report was successfully generated. Creating artifact for the build. Artifact was added to the build. [Pipeline] } [Pipeline] // stage [Pipeline] } [Pipeline] // dir [Pipeline] } [Pipeline] // node [Pipeline] } [Pipeline] // throttle [Pipeline] End of Pipeline Finished: SUCCESS Resuming build at Wed Oct 26 06:20:19 UTC 2022 after Jenkins restart [Pipeline] End of Pipeline java.io.FileNotFoundException: / var /lib/jenkins/jobs/Automation-Stylezone-Manual/builds/3/program.dat (No such file or directory) at java.base/java.io.FileInputStream.open0(Native Method) at java.base/java.io.FileInputStream.open(FileInputStream.java:216)    

          Benjamin added a comment -

          Looks like Jenkins 2.361.3 fixed the issue

          Benjamin added a comment - Looks like Jenkins 2.361.3 fixed the issue

            Unassigned Unassigned
            gfjalar Piotr Galar
            Votes:
            2 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated: