InterruptedException during initial checkout leads to FAILURE instead of ABORT

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      An aborted build should have the status ABORTED. The status is FAILURE if the build gets aborted during the initial checkout. An interrupted exception should be handled gracefully and lead to ABORTED (also no repeats of the checkout should be triggered).

      I came across this issue while working on JENKINS-72819. Here the InterruptedException is causing a NPE in the exception handler in the git-client-plugin. After fixing this issue I now get the following call stack in case of an early abort. The last line is saying FAILURE which should be ABORTED.
       
      ERROR: Checkout failed
      java.lang.InterruptedException
      at java.base/java.lang.Object.wait(Native Method)
      at java.base/java.lang.Object.wait(Unknown Source)
      at java.base/java.lang.ProcessImpl.waitFor(Unknown Source)
      at hudson.Proc$LocalProc.join(Proc.java:328)
      at hudson.Proc.joinWithTimeout(Proc.java:172)
      at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2839)
      at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandWithCredentials(CliGitAPIImpl.java:2185)
      at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$1.execute(CliGitAPIImpl.java:635)
      at org.jenkinsci.plugins.gitclient.CliGitAPIImpl$2.execute(CliGitAPIImpl.java:871)
      at hudson.plugins.git.GitSCM.retrieveChanges(GitSCM.java:1222)
      at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1305)
      at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:129)
      at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:165)
      at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:71)
      at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:311)
      at hudson.model.ResourceController.execute(ResourceController.java:101)
      at hudson.model.Executor.run(Executor.java:442)
      ERROR: Maximum checkout retry attempts reached, aborting
      Finished: FAILURE
       
       

            Assignee:
            Unassigned
            Reporter:
            Christoph Kulla
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: