-
-
Save imeredith/7c045cf3d015c21fbc85 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/core/src/main/java/hudson/model/ComputerSet.java b/core/src/main/java/hudson/model/ComputerSet.java | |
index 03ddfbb..21999f8 100644 | |
--- a/core/src/main/java/hudson/model/ComputerSet.java | |
+++ b/core/src/main/java/hudson/model/ComputerSet.java | |
@@ -140,7 +140,7 @@ public final class ComputerSet extends AbstractModelObject { | |
public int getTotalExecutors() { | |
int r=0; | |
for (Computer c : get_all()) { | |
- if(c.isOnline()) | |
+ if(c.getNode().getMode() != Node.Mode.EXCLUSIVE && c.isOnline()) | |
r += c.countExecutors(); | |
} | |
return r; | |
@@ -153,7 +153,7 @@ public final class ComputerSet extends AbstractModelObject { | |
public int getBusyExecutors() { | |
int r=0; | |
for (Computer c : get_all()) { | |
- if(c.isOnline()) | |
+ if(c.getNode().getMode() != Node.Mode.EXCLUSIVE && c.isOnline()) | |
r += c.countBusy(); | |
} | |
return r; | |
@@ -165,7 +165,7 @@ public final class ComputerSet extends AbstractModelObject { | |
public int getIdleExecutors() { | |
int r=0; | |
for (Computer c : get_all()) | |
- if(c.isOnline() || c.isConnecting()) | |
+ if(c.getNode().getMode() != Node.Mode.EXCLUSIVE && (c.isOnline() || c.isConnecting())) | |
r += c.countIdle(); | |
return r; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment