Skip to content

Instantly share code, notes, and snippets.

View malonem's full-sized avatar

Mark Malone malonem

View GitHub Profile
@malonem
malonem / find-dead-executors.groovy
Created February 27, 2013 05:30
Jenkins script to find dead executors and remove them.
// get handle to build output
def config = new HashMap()
def bindings = getBinding()
config.putAll(bindings.getVariables())
def out = config['out']
for (aSlave in hudson.model.Hudson.instance.slaves) {
// check if executor is dead
execList = aSlave.getComputer().getExecutors()
for( exec in execList ) {