hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From la...@apache.org
Subject svn commit: r1330549 - in /hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master: AssignmentManager.java HMaster.java
Date Wed, 25 Apr 2012 20:43:02 GMT
Author: larsh
Date: Wed Apr 25 20:43:01 2012
New Revision: 1330549

URL: http://svn.apache.org/viewvc?rev=1330549&view=rev
Log:
HBASE-5873 TimeOut Monitor thread should be started after atleast one region server registers.

Modified:
    hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java
    hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/HMaster.java

Modified: hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java?rev=1330549&r1=1330548&r2=1330549&view=diff
==============================================================================
--- hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java
(original)
+++ hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java
Wed Apr 25 20:43:01 2012
@@ -207,14 +207,17 @@ public class AssignmentManager extends Z
       conf.getInt("hbase.master.assignment.timeoutmonitor.period", 10000),
       master, serverManager,
       conf.getInt("hbase.master.assignment.timeoutmonitor.timeout", 1800000));
-    Threads.setDaemonThreadRunning(timeoutMonitor.getThread(),
-      master.getServerName() + ".timeoutMonitor");
     this.zkTable = new ZKTable(this.master.getZooKeeper());
     this.maximumAssignmentAttempts =
       this.master.getConfiguration().getInt("hbase.assignment.maximum.attempts", 10);
     this.balancer = balancer;
     this.threadPoolExecutorService = Executors.newCachedThreadPool();
   }
+  
+  void startTimeOutMonitor() {
+    Threads.setDaemonThreadRunning(timeoutMonitor.getThread(), master.getServerName()
+        + ".timeoutMonitor");
+  }
 
   /**
    * Compute the average load across all region servers.

Modified: hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/HMaster.java?rev=1330549&r1=1330548&r2=1330549&view=diff
==============================================================================
--- hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/HMaster.java (original)
+++ hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/master/HMaster.java Wed Apr
25 20:43:01 2012
@@ -514,6 +514,7 @@ Server {
       }
     }
 
+    this.assignmentManager.startTimeOutMonitor();
     Set<ServerName> onlineServers = new HashSet<ServerName>(serverManager
         .getOnlineServers().keySet());
     // TODO: Should do this in background rather than block master startup



Mime
View raw message