Deadlock between Queue and Jenkins model

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

XMLWordPrintable

      When a node is removed (synchronized Jenkins.removeNode()), then eventually Computer.setNumExecutors() is called, attempting to lock the Queue. If, at the same time, a CloudRetentionStrategy.check() runs and determines that a node should be terminated, it locks the Queue before calling Jenkins.removeNode() and attempting to get a lock on the Jenkins object.

      A thread dump (deadlock.tdump) is attached which shows the deadlock.

      We're using DockerComputers that use the OnceRetentionStrategy, which means that nodes are removed every time a task completes, so the potential for this deadlock occurring is quite high (we experience it multiple times per day).

            Assignee:
            Stephen Connolly
            Reporter:
            Bernie Schelberg
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: