From 163075379c27c4ef4dd8ad97d5fb0de2a216c386 Mon Sep 17 00:00:00 2001 From: jeffreyz Date: Tue, 10 Dec 2013 01:55:28 +0000 Subject: [PATCH] HBASE-10059: TestSplitLogWorker#testMultipleTasks fails occasionally git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1549738 13f79535-47bb-0310-9956-ffa450edef68 --- .../hadoop/hbase/regionserver/TestSplitLogWorker.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSplitLogWorker.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSplitLogWorker.java index ef56d0cee10..008b89a608f 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSplitLogWorker.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSplitLogWorker.java @@ -235,7 +235,7 @@ public class TestSplitLogWorker { assertTrue(slt.isOwned(SRV)); slt = new SplitLogTask.Unassigned(MANAGER); ZKUtil.setData(zkw, PATH, slt.toByteArray()); - waitForCounter(SplitLogCounters.tot_wkr_preempt_task, 0, 1, 1500); + waitForCounter(SplitLogCounters.tot_wkr_preempt_task, 0, 1, 5000); } finally { stopSplitLogWorker(slw); } @@ -254,13 +254,13 @@ public class TestSplitLogWorker { try { Thread.yield(); // let the worker start Thread.sleep(100); - waitForCounter(SplitLogCounters.tot_wkr_task_grabing, 0, 1, 1500); + waitForCounter(SplitLogCounters.tot_wkr_task_grabing, 0, 1, 5000); SplitLogTask unassignedManager = new SplitLogTask.Unassigned(MANAGER); zkw.getRecoverableZooKeeper().create(PATH1, unassignedManager.toByteArray(), Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT); - waitForCounter(SplitLogCounters.tot_wkr_task_acquired, 0, 1, 1500); + waitForCounter(SplitLogCounters.tot_wkr_task_acquired, 0, 1, 5000); // now the worker is busy doing the above task // create another task @@ -272,9 +272,9 @@ public class TestSplitLogWorker { final ServerName anotherWorker = ServerName.valueOf("another-worker,1,1"); SplitLogTask slt = new SplitLogTask.Owned(anotherWorker); ZKUtil.setData(zkw, PATH1, slt.toByteArray()); - waitForCounter(SplitLogCounters.tot_wkr_preempt_task, 0, 1, 1500); + waitForCounter(SplitLogCounters.tot_wkr_preempt_task, 0, 1, 5000); - waitForCounter(SplitLogCounters.tot_wkr_task_acquired, 1, 2, 1500); + waitForCounter(SplitLogCounters.tot_wkr_task_acquired, 1, 2, 5000); assertEquals(2, slw.taskReadySeq); byte [] bytes = ZKUtil.getData(zkw, PATH2); slt = SplitLogTask.parseFrom(bytes);