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

jclouds single-use slave never cleaned up

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Component/s: jclouds-plugin
    • Labels:
      None
    • Environment:
      Jenkins 2.229
      jclouds plugin 2.17
    • Similar Issues:

      Description

      When I use the jclouds plugin to spawn instances at DigitalOcean and EC2, I noticed that the single-use slaves are never removed. They are marked offline as soon as the job finishes, but they remain offline in Jenkins and they are active with the cloud provider.

      As soon as the job finishes, I see this in the logs:

       2020-04-02 18:30:42.634+0000 [id=3070]	WARNING	j.p.j.c.JCloudsOneOffSlave$JCloudsOneOffSlaveDisposer#tearDown: Taking single-use slave [COMPUTER_NAME] offline.
      

      I let it sit for two hours and nothing changed. I had to delete the agent manually from inside Jenkins' build executors listing.

      Am I missing a step? I'll gladly turn on more debug logging if that would help diagnose the issue.

        Attachments

          Activity

          Hide
          felfert Fritz Elfert added a comment -

          Well this turned out to be a bug. The retention time for the single-use slaves was never reset to zero.

          Therefore, the normal RetentionStrategy handler never touched them. Will fix this asap.

          -Fritz

          Show
          felfert Fritz Elfert added a comment - Well this turned out to be a bug. The retention time for the single-use slaves was never reset to zero. Therefore, the normal RetentionStrategy handler never touched them. Will fix this asap. -Fritz
          Hide
          felfert Fritz Elfert added a comment - - edited

          Please try this build. If this fixes the problem for you, I will create a new release.

          Show
          felfert Fritz Elfert added a comment - - edited Please try this build . If this fixes the problem for you, I will create a new release.
          Hide
          mhayden Major Hayden added a comment -

          Thanks for the quick fix. I'll try to get a look at this as soon as I can.

          Show
          mhayden Major Hayden added a comment - Thanks for the quick fix. I'll try to get a look at this as soon as I can.
          Hide
          felfert Fritz Elfert added a comment -

          As I got no further feedback, I now released v1.18 and close this issue.

          Feel free to reopen this issue, if you are not satisfied with the solution.

          Note: A slight delay (~ 1min) is still happening between marking a slave offline and actually deleting the instance in the cloud. This works as designed.

          Show
          felfert Fritz Elfert added a comment - As I got no further feedback, I now released v1.18 and close this issue. Feel free to reopen this issue, if you are not satisfied with the solution. Note: A slight delay (~ 1min) is still happening between marking a slave offline and actually deleting the instance in the cloud. This works as designed.

            People

            Assignee:
            felfert Fritz Elfert
            Reporter:
            mhayden Major Hayden
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: