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

lockable-resources resource autocomplete creates faulty resource names

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • None
    • lockable-resources plugin 2.0

      Locking a job with a resource name won't work, if using the autocompleted resource name. Two jobs requiring the same lock can be run in parallel.

      Steps to reproduce:

      1. In the Jenkins configuration, create a lockable resource called 'abcd'
      2. Create a new freestyle job, in the configuration choose 'This build requires lockable resources' and type 'ab' to 'Resources'. The autocomplete should now offer you 'abcd', click on that.
      3. Click save.
      4. Build your new project.
      5. Open the console. It should say

      [lockable-resources] acquired lock on [](it should have said acquired lock on [abcd].

      The problem seems to be, that the plugin writes to the jobs config.xml an extra space character, e.g.

      <resourceNames>abcd </resourceNames>

      instead of <resourceNames>abcd</resourceNames>

       

       

            Unassigned Unassigned
            aga Aleksi Aalto
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: