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

Add support of throttling of the entire build in Declarative Pipeline


      So, I'm having this problem that I described in a similar bug for the lockable-resource plugin (JENKINS-45138). I said to myself, "oh, hey, I remember being able to throttle executions on a per-agent basis!"

      Imagine my surprise when I hit the documentation and find that throttle is only applicable inside a step.

      I need to acquire, use, and cleanup exclusive access to a resource on each agent. Will throttle work how I expect?

      step('foo') {
          bat '... acquire the resource...'
          bat '... use the resource...'
      post {
          always {
              bat '... cleanup the resource...'

            Unassigned Unassigned
            anthonymastrean Anthony Mastrean
            32 Vote for this issue
            41 Start watching this issue