HBASE-15360 Fix flaky TestSimpleRpcScheduler (Duo Zhang)

This commit is contained in:
stack 2016-03-16 08:04:10 -07:00
parent f120602f1e
commit 9eb25bd5c9
1 changed files with 3 additions and 1 deletions

View File

@ -354,7 +354,9 @@ public class TestSimpleRpcScheduler {
schedConf.setInt("hbase.ipc.server.max.callqueue.length", 0);
scheduler.onConfigurationChange(schedConf);
assertFalse(scheduler.dispatch(putCallTask));
while (scheduler.getGeneralQueueLength() > 0) {
Threads.sleepWithoutInterrupt(100);
}
schedConf.setInt("hbase.ipc.server.max.callqueue.length", 1);
scheduler.onConfigurationChange(schedConf);
assertTrue(scheduler.dispatch(putCallTask));