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

Cloud provisioning called when Jenkins is quieting Down

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • core
    • None

      If Jenkins is quieting down and there are builds in the queue, nodes are still provisioned from any clouds.

      Ideally, Jenkins would not provision new slaves when it is supposed to be quieting down.

          [JENKINS-20967] Cloud provisioning called when Jenkins is quieting Down

          Ryan Campbell created issue -

          Ryan Campbell added a comment -

          It seems that the root cause is that each label's LoadStatistics are still reporting queue lengths over zero.

          So a simple fix would just have hudson.slaves.NodeProvisioner#update not provision if Jenkins.isQuietingDown().

          Ryan Campbell added a comment - It seems that the root cause is that each label's LoadStatistics are still reporting queue lengths over zero. So a simple fix would just have hudson.slaves.NodeProvisioner#update not provision if Jenkins.isQuietingDown().

          Thomas Suckow added a comment -

          Changing NodeProvisioner would create a deadlock situation with NonBlockingTasks, such as a Matrix Build. Their slaves may never get created. I think it would be more appropriate to modify the behaviour of countBuildable*() in Queue to only count tasks that are not blocked by shutdown.

          I have another pull request manipulating countBuildable, I may make a pull request for this after that one gets accepted.

          Thomas Suckow added a comment - Changing NodeProvisioner would create a deadlock situation with NonBlockingTasks, such as a Matrix Build. Their slaves may never get created. I think it would be more appropriate to modify the behaviour of countBuildable*() in Queue to only count tasks that are not blocked by shutdown. I have another pull request manipulating countBuildable, I may make a pull request for this after that one gets accepted.

          Jesse Glick added a comment -

          Jesse Glick added a comment - Better wait for https://github.com/jenkinsci/jenkins/pull/1596 .

          Any news?

          Kanstantsin Shautsou added a comment - Any news?
          Kanstantsin Shautsou made changes -
          Assignee New: Stephen Connolly [ stephenconnolly ]

          Highlight.

          Kanstantsin Shautsou added a comment - Highlight.
          Jesse Glick made changes -
          Link New: This issue is related to JENKINS-27565 [ JENKINS-27565 ]

          Thomas Suckow added a comment -

          For anyone interested. I had started work on straightening out countBuildable* but a conflicting change made mine unmergable. I don't have the time to look into this in the near future, but my work is still at https://github.com/thomassuckow/jenkins/commits/feature/fix-stuck-queue

          Thomas Suckow added a comment - For anyone interested. I had started work on straightening out countBuildable* but a conflicting change made mine unmergable. I don't have the time to look into this in the near future, but my work is still at https://github.com/thomassuckow/jenkins/commits/feature/fix-stuck-queue
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 152778 ] New: JNJira + In-Review [ 178327 ]

            Unassigned Unassigned
            recampbell Ryan Campbell
            Votes:
            2 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated: