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

RFE: input() blocks the executor in Declarative, add a stage attribute instead?

    • Icon: Improvement Improvement
    • Resolution: Duplicate
    • Icon: Major Major
    • None
    • Jenkins LTS 2.72 rpm on SLES 11 SP 4

      When using an input step in pipeline, the executor is blocked until you proceed or abort the input step.

      We have here the case that the code is build whenever it is changed in the scm via polling.
      Only a small number of the builds going to development, staging and production.
      As the executor is blocked, the maximum number of executors is reached in short time.

      The build pipeline plugin instead use an executor for every job it contains.

      Is it possible to break end the executor when input step is reached and restart after proceed answer?

          [JENKINS-37515] RFE: input() blocks the executor in Declarative, add a stage attribute instead?

          Torsten Kleiber created issue -

          I think the issue will be with workspace. Executor will hold workspace that may be needed for continuation after input. Some adittional non-blocking input maybe needs to be created?

          Kanstantsin Shautsou added a comment - I think the issue will be with workspace. Executor will hold workspace that may be needed for continuation after input. Some adittional non-blocking input maybe needs to be created?

          Jesse Glick added a comment -

          If you need to release the executor, put input outside node. If you need to keep some files from the workspace, stash them before you leave.

          Jesse Glick added a comment - If you need to release the executor, put input outside node . If you need to keep some files from the workspace, stash them before you leave.
          Jesse Glick made changes -
          Resolution New: Not A Defect [ 7 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]

          Thanks for the tip jglick, that resolved it for me.

          Katherine Morgan added a comment - Thanks for the tip jglick , that resolved it for me.
          Torsten Kleiber made changes -
          Attachment New: 20160912_070739.png [ 33901 ]

          Torsten Kleiber added a comment - - edited

          In which version do you have tested this, does not work in 2.7.2 here with following example :

          {node

          { stage 'Build after Commit' } stage 'Deploy against developement' input 'Are you sure?'}

          Torsten Kleiber added a comment - - edited In which version do you have tested this, does not work in 2.7.2 here with following example : {node { stage 'Build after Commit' } stage 'Deploy against developement' input 'Are you sure?'}

          See my last comment.

          Torsten Kleiber added a comment - See my last comment.
          Torsten Kleiber made changes -
          Resolution Original: Not A Defect [ 7 ]
          Status Original: Resolved [ 5 ] New: Reopened [ 4 ]
          Katherine Morgan made changes -
          Attachment New: jenkins-build-executor.PNG [ 33906 ]

            Unassigned Unassigned
            tkleiber Torsten Kleiber
            Votes:
            2 Vote for this issue
            Watchers:
            10 Start watching this issue

              Created:
              Updated:
              Resolved: