jenkins error failed to interrupt and stop 1 build code example
Example: stop all runs of a job jenkins
Jenkins.instance.getItemByFullName("JobName")
.getBuildByNumber(JobNumber)
.finish(
hudson.model.Result.ABORTED,
new java.io.IOException("Aborting build")
);