ExportXMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Major
    • Component/s: spotinst-plugin
    • None
    • Environment:
      Ubuntu 24.04.2 LTS
      openjdk 21.0.11 2026-04-21 LTS
      OpenJDK Runtime Environment Corretto-21.0.11.10.1 (build 21.0.11+10-LTS)
      OpenJDK 64-Bit Server VM Corretto-21.0.11.10.1 (build 21.0.11+10-LTS, mixed mode, sharing)

      See the attached threaddump.txt which captures a deadlock situation in our Jenkins.

      As far as my analysis goes it feels that this is caused by the spotinst plugin.

      Two locks are involved:

      • the build queue lock
      • the lock of the spotinstance agent

      And as far as I can see hudson.slaves.ComputerRetentionWork first gets the build queue lock and then tries to get the agent lock.

      However hudson.plugins.spotinst.jobs.SpotinstInstancesMonitor first gets the agent lock and then invokes removeNode which tries to get the build queue lock.

      So lock ordering is violated which leads to this deadlock situation.

      Probably a way to fix that would be to just schedule a separate job to perform "removeNode".

       

            Assignee:
            Aharon Twizer
            Reporter:
            Christian
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: