Hi,
Is there a way to remove a job from the job queue using a groovy api?
Right now, if I hover my mouse over the red "x" button of a job in the
queue, I can see the remove-from-queue-URL is something like:
http://my.jenkins:8080/queue/item/15/cancelQueue
If I print out all methods and properties for an item of a queue, nothings
stands out to me as the cancel action:
for (anItem in hudson.model.Hudson.instance.getQueue().getItems()) {
  anItem.metaClass.methods.each{ p ->
    println(p);
  }
  anItem.metaClass.properties.each { p ->
    println("======================");
    println p.name;
    println p.type;
  } 
}
Any ideas how to do this?
Thanks!

--
View this message in context: 
http://jenkins.361315.n4.nabble.com/Remove-job-from-queue-via-groovy-tp4558034p4558034.html
Sent from the Jenkins users mailing list archive at Nabble.com.

Reply via email to