On systems with slaves you can now configure the utilization mode of master.

(<a href="http://www.nabble.com/Master-Usage%2C-Execution-Plot%2C-Build-Visualizer-tt17883797.html">report</a>)


git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@10177 71c3de6d-444a-0410-be80-ed276b4c234a
This commit is contained in:
kohsuke committed 2008-06-17 19:59:36 +00:00
1 parent 7a05d38cc0
commit 38fd216b56
2 files changed
+26 -9

No files matched your search

+10 -1
View File
@@ -156,6 +156,11 @@ public final class Hudson extends View implements ItemGroup<TopLevelItem>, Node,
*/
private int numExecutors = 2;
/**
* Job allocation strategy.
*/
private Mode mode = Mode.NORMAL;
/**
* False to enable anyone to do anything.
* Left as a field so that we can still read old data that uses this flag.
@@ -1226,7 +1231,7 @@ public final class Hudson extends View implements ItemGroup<TopLevelItem>, Node,
}
public Mode getMode() {
return Mode.NORMAL;
return mode;
}
public Set<Label> getAssignedLabels() {
@@ -1524,6 +1529,10 @@ public final class Hudson extends View implements ItemGroup<TopLevelItem>, Node,
JSONObject json = StructuredForm.get(req);
numExecutors = Integer.parseInt(req.getParameter("numExecutors"));
if(req.hasParameter("master.mode"))
mode = Mode.valueOf(req.getParameter("master.mode"));
else
mode = Mode.NORMAL;
{
// update slave list