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

Future returned from scheduleBuild2 cannot be taken out of queue

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • core
    • None

      I am attempting to use Future's cancel() method in the Gerrit trigger plugin (https://github.com/jenkinsci/gerrit-trigger-plugin/pull/5) to ensure that only the current version of a Gerrit patch is built. This works fine if the build is already in progress, but calling cancel() on the result of scheduleBuild2() when it is in the queue does not remove it from the queue.

      This doesn't seem intended to me, but if it is, can you please provide me with the method to do what I am describing?

      Thanks

            abayer Andrew Bayer
            bnovc bnovc
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: