3a57331a54
There is a host scheduler managing the host locking. When it can acquire a lock over the host it will delegate all the tasks related to that host to the same scheduler. This scheduler will take care of how many jobs it will submit, and in which order. It's also responsible for guaranteeing the execution order per user. Capacity planner dictates how many jobs can be run at the same time in a given host. There are two simple strategies: 1. Infinity: it will attempt to run as many jobs as different users. 2. One: it will run just one job at the same time. Missing things: - Handle lock renewal failures. - Fair scheduling for pending/waiting users. - Capacity based on real resources.
12 lines
187 B
JavaScript
12 lines
187 B
JavaScript
'use strict';
|
|
|
|
function InfinityCapacity() {
|
|
|
|
}
|
|
|
|
module.exports = InfinityCapacity;
|
|
|
|
InfinityCapacity.prototype.getCapacity = function(callback) {
|
|
return callback(null, Infinity);
|
|
};
|