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

Resorce is not released when manually cancelling a job during SVN updates (first part of job)

    Details

    • Similar Issues:

      Description

      When I cancel a build during ANT all seems ok and the resource is released:

      Releasing previously locked resource: 10101010101...
      Resource 10101010101 successfully released.
      

      But when I cancel a job while it's doing SVN updates, it will not release it's resource (no output as above in console + on the manage jenkins - nodes - master I see that resource still marked as "reserved") and then all next scheduled jobs starve. I only have a master node, no slave - so very simple setup.

      It probably happens because the resource is "reserved" not "locked" so it doesn't have something to actually unlock, but it should also "unreserve". I tried it with default reservation time setting of 3 seconds and also with 0 seconds.

        Attachments

          Activity

          Hide
          ebichel Eduard Bichel added a comment -

          Was the resource still reserved after some time? There is a bug in the currently released version, that queued items can starve when they already reserved resources once.
          Which resource manager were you using?

          Show
          ebichel Eduard Bichel added a comment - Was the resource still reserved after some time? There is a bug in the currently released version, that queued items can starve when they already reserved resources once. Which resource manager were you using?
          Hide
          costescuandrei Andrei Costescu added a comment -

          Yes, I remember it remained reserved for a long long time - with no job running (even over night) and no job that needed the resource could start.
          NoopExternalResourceManager. I don't remember the setting used for reservation time, but I think I did try some settings of a few seconds, even -1, but with no difference.

          Show
          costescuandrei Andrei Costescu added a comment - Yes, I remember it remained reserved for a long long time - with no job running (even over night) and no job that needed the resource could start. NoopExternalResourceManager. I don't remember the setting used for reservation time, but I think I did try some settings of a few seconds, even -1, but with no difference.
          Hide
          ebichel Eduard Bichel added a comment -

          Okay, I can't verify it, but it seems to me, that it is the bug I fixed a while ago. I don't know if it is in the current release, but I think it's not.
          The NoopExternalResourceManager should be avoided IMHO, because in some cases another job can lock a resource another job has reserved. Noop does not check if the locking job is the one, that reserved it.
          If you still consider using this plugin, please wait a bit. I do have a bigger patchset in the pipeline with a new, more usable resource manager implementation than Noop.

          Show
          ebichel Eduard Bichel added a comment - Okay, I can't verify it, but it seems to me, that it is the bug I fixed a while ago. I don't know if it is in the current release, but I think it's not. The NoopExternalResourceManager should be avoided IMHO, because in some cases another job can lock a resource another job has reserved. Noop does not check if the locking job is the one, that reserved it. If you still consider using this plugin, please wait a bit. I do have a bigger patchset in the pipeline with a new, more usable resource manager implementation than Noop.
          Hide
          costescuandrei Andrei Costescu added a comment -

          Ok, thanks.

          Show
          costescuandrei Andrei Costescu added a comment - Ok, thanks.

            People

            • Assignee:
              rsandell rsandell
              Reporter:
              costescuandrei Andrei Costescu
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: