mirror of https://github.com/apache/druid.git
Merge branch 'master' of github.com:metamx/druid
This commit is contained in:
commit
6ddb014671
|
@ -323,14 +323,15 @@ public class SimpleResourceManagementStrategy implements ResourceManagementStrat
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
final boolean atSteadyState = currentlyProvisioning.isEmpty()
|
final boolean notTakingActions = currentlyProvisioning.isEmpty()
|
||||||
&& currentlyTerminating.isEmpty()
|
&& currentlyTerminating.isEmpty();
|
||||||
&& validWorkers.size() == targetWorkerCount;
|
final boolean shouldScaleUp = notTakingActions
|
||||||
final boolean shouldScaleUp = atSteadyState
|
&& validWorkers.size() >= targetWorkerCount
|
||||||
&& targetWorkerCount < maxWorkerCount
|
&& targetWorkerCount < maxWorkerCount
|
||||||
&& (hasTaskPendingBeyondThreshold(pendingTasks)
|
&& (hasTaskPendingBeyondThreshold(pendingTasks)
|
||||||
|| targetWorkerCount < minWorkerCount);
|
|| targetWorkerCount < minWorkerCount);
|
||||||
final boolean shouldScaleDown = atSteadyState
|
final boolean shouldScaleDown = notTakingActions
|
||||||
|
&& validWorkers.size() == targetWorkerCount
|
||||||
&& targetWorkerCount > minWorkerCount
|
&& targetWorkerCount > minWorkerCount
|
||||||
&& Iterables.any(validWorkers, isLazyWorker);
|
&& Iterables.any(validWorkers, isLazyWorker);
|
||||||
if (shouldScaleUp) {
|
if (shouldScaleUp) {
|
||||||
|
|
Loading…
Reference in New Issue