HBASE-5328 Small changes to Master to make it more testable

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1303648 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael Stack 2012-03-22 03:40:46 +00:00
parent 327e2d1f74
commit 772ecdd236
2 changed files with 3 additions and 3 deletions

View File

@ -479,7 +479,7 @@ Server {
return new CatalogTracker(zk, conf, abortable, defaultTimeout); return new CatalogTracker(zk, conf, abortable, defaultTimeout);
} }
// Check if we should stop every second. // Check if we should stop every 100ms
private Sleeper stopSleeper = new Sleeper(100, this); private Sleeper stopSleeper = new Sleeper(100, this);
private void loop() { private void loop() {
while (!this.stopped) { while (!this.stopped) {

View File

@ -104,7 +104,7 @@ public class TestMasterNoCluster {
* @throws KeeperException * @throws KeeperException
* @throws InterruptedException * @throws InterruptedException
*/ */
@Test @Test (timeout=30000)
public void testStopDuringStart() public void testStopDuringStart()
throws IOException, KeeperException, InterruptedException { throws IOException, KeeperException, InterruptedException {
HMaster master = new HMaster(TESTUTIL.getConfiguration()); HMaster master = new HMaster(TESTUTIL.getConfiguration());
@ -326,4 +326,4 @@ public class TestMasterNoCluster {
master.join(); master.join();
} }
} }
} }