YARN-9325. TestQueueManagementDynamicEditPolicy fails intermittent. Contributed by Prabhu Joseph.

(cherry picked from commit 1c8046d67e)
This commit is contained in:
Weiwei Yang 2019-04-23 14:21:13 +08:00
parent 9da70a1b4b
commit d242b166ed
1 changed files with 1 additions and 1 deletions

View File

@ -118,7 +118,7 @@ public class TestQueueManagementDynamicEditPolicy extends
nodeLabel, int timesec) throws InterruptedException { nodeLabel, int timesec) throws InterruptedException {
long start = System.currentTimeMillis(); long start = System.currentTimeMillis();
while (System.currentTimeMillis() - start < timesec * 1000) { while (System.currentTimeMillis() - start < timesec * 1000) {
if (Float.compare(expectedVal, queueManagementPolicy if (Math.abs(expectedVal - queueManagementPolicy
.getAbsoluteActivatedChildQueueCapacity(nodeLabel)) > EPSILON) { .getAbsoluteActivatedChildQueueCapacity(nodeLabel)) > EPSILON) {
Thread.sleep(100); Thread.sleep(100);
} else { } else {