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

Honor SCM checkout retry count from CpsScmFlowDefinition

    Details

    • Similar Issues:
    • Released As:
      Pipeline Groovy 2.44

      Description

      Hi Team,

      We have set the value of SCM checkout retry count to 5. This is working well for free style jobs. The same is not working while loading pipeline using "Pipeline script from scm" option.

      This could be a bug. Can you please check into this.

      Thanks!

        Attachments

        1. SCMRetryCount.PNG
          SCMRetryCount.PNG
          13 kB
        2. Pipeline_Output.PNG
          Pipeline_Output.PNG
          117 kB
        3. Pipeline_Configuration.PNG
          Pipeline_Configuration.PNG
          38 kB
        4. FreeStyle_Output.PNG
          FreeStyle_Output.PNG
          159 kB
        5. FreeStyle_Configuration.PNG
          FreeStyle_Configuration.PNG
          48 kB

          Activity

          Hide
          jglick Jesse Glick added a comment -

          As long as it goes into an f:advanced block.

          Show
          jglick Jesse Glick added a comment - As long as it goes into an f:advanced block.
          Show
          mmitche Matthew Mitchell added a comment - Implemented in  https://github.com/jenkinsci/workflow-cps-plugin/pull/147
          Hide
          asegretto Anthony Segretto added a comment -

          The retry feature on Pipelines would be extremely helpful for us.  Our SCM is often unreliable where a checkout will time out:

          stderr: fatal: unable to access 'https://tfs-...': Failed to connect to tfs-... port 443: Timed out

           

          We implement retries around the git fetches completed within the pipeline itself, and typically a single retry will do the trick.  Short of using pull/147 I don't see any way for us to work around the issue of failed git fetches within the (Declarative: Checkout SCM) stage.  We are not interested in installing an unofficial fix.

           

          The fix mentioned on this issue would resolve our current most frequent reason of build failures.  Is there an ETA for resolution?

          Show
          asegretto Anthony Segretto added a comment - The retry feature on Pipelines would be extremely helpful for us.  Our SCM is often unreliable where a checkout will time out: stderr: fatal: unable to access 'https://tfs-...': Failed to connect to tfs-... port 443: Timed out   We implement retries around the git fetches completed within the pipeline itself, and typically a single retry will do the trick.  Short of using pull/147 I don't see any way for us to work around the issue of failed git fetches within the (Declarative: Checkout SCM) stage.  We are not interested in installing an unofficial fix.   The fix mentioned on this issue would resolve our current most frequent reason of build failures.  Is there an ETA for resolution?
          Hide
          zmh998 Minghua Zhao added a comment -

          Is there any update for this issue? I saw the pull request was approved but not merged.

          Show
          zmh998 Minghua Zhao added a comment - Is there any update for this issue? I saw the pull request was approved but not merged.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Sam Van Oort
          Path:
          src/main/java/org/jenkinsci/plugins/workflow/cps/CpsScmFlowDefinition.java
          src/test/java/org/jenkinsci/plugins/workflow/cps/CpsScmFlowDefinitionTest.java
          http://jenkins-ci.org/commit/workflow-cps-plugin/d91d14d0323d0944dc5a89fef83c83283c7d13d9
          Log:
          Merge pull request #147 from mmitche/add-retry

          JENKINS-39194 Implement SCM retry count

          Compare: https://github.com/jenkinsci/workflow-cps-plugin/compare/e9b183243542...d91d14d0323d

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Sam Van Oort Path: src/main/java/org/jenkinsci/plugins/workflow/cps/CpsScmFlowDefinition.java src/test/java/org/jenkinsci/plugins/workflow/cps/CpsScmFlowDefinitionTest.java http://jenkins-ci.org/commit/workflow-cps-plugin/d91d14d0323d0944dc5a89fef83c83283c7d13d9 Log: Merge pull request #147 from mmitche/add-retry JENKINS-39194 Implement SCM retry count Compare: https://github.com/jenkinsci/workflow-cps-plugin/compare/e9b183243542...d91d14d0323d

            People

            • Assignee:
              mmitche Matthew Mitchell
              Reporter:
              anudeeplalam Anudeep Lalam
            • Votes:
              2 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: