hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject svn commit: r1098023 - in /hbase/trunk/src/main/java/org/apache/hadoop/hbase: ipc/WritableRpcEngine.java master/AssignmentManager.java regionserver/SplitLogWorker.java zookeeper/ZKSplitLog.java
Date Fri, 29 Apr 2011 23:25:18 GMT
Author: stack
Date: Fri Apr 29 23:25:18 2011
New Revision: 1098023

URL: http://svn.apache.org/viewvc?rev=1098023&view=rev
Log:
HBASE-3832 Failing TestMasterFailover.testMasterFailoverWithMockedRITOnDeadRS up on jenkins;
added debug and cleared out extra regionOnline of -ROOT-

Modified:
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/ipc/WritableRpcEngine.java
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/SplitLogWorker.java
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKSplitLog.java

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/ipc/WritableRpcEngine.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/ipc/WritableRpcEngine.java?rev=1098023&r1=1098022&r2=1098023&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/ipc/WritableRpcEngine.java (original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/ipc/WritableRpcEngine.java Fri Apr 29
23:25:18 2011
@@ -141,8 +141,8 @@ class WritableRpcEngine implements RpcEn
                     protocol, ticket, rpcTimeout);
       if (logDebug) {
         // FIGURE HOW TO TURN THIS OFF!
-        // long callTime = System.currentTimeMillis() - startTime;
-        // LOG.debug("Call: " + method.getName() + " " + callTime);
+        long callTime = System.currentTimeMillis() - startTime;
+        LOG.debug("Call: " + method.getName() + " " + callTime);
       }
       return value.get();
     }

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java?rev=1098023&r1=1098022&r2=1098023&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java (original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java Fri Apr
29 23:25:18 2011
@@ -226,13 +226,6 @@ public class AssignmentManager extends Z
     // TODO: Regions that have a null location and are not in regionsInTransitions
     // need to be handled.
 
-    // Add -ROOT- and .META. on regions map.  They must be deployed if we got
-    // this far.
-    ServerName sn = this.catalogTracker.getMetaLocation();
-    regionOnline(HRegionInfo.FIRST_META_REGIONINFO, sn);
-    sn = this.catalogTracker.getRootLocation();
-    regionOnline(HRegionInfo.ROOT_REGIONINFO, sn);
-
     // Scan META to build list of existing regions, servers, and assignment
     // Returns servers who have not checked in (assumed dead) and their regions
     Map<ServerName,List<Pair<HRegionInfo,Result>>> deadServers =
@@ -243,28 +236,29 @@ public class AssignmentManager extends Z
     processRegionsInTransition();
   }
 
-  public void processRegionsInTransition()
+  void processRegionsInTransition()
   throws KeeperException, IOException, InterruptedException {
     List<String> nodes = ZKUtil.listChildrenAndWatchForNewChildren(watcher,
       watcher.assignmentZNode);
     // Run through all regions.  If they are not assigned and not in RIT, then
     // its a clean cluster startup, else its a failover.
-    boolean userRegionsOutOnCluster = false;
+    boolean regionsToProcess = false;
     for (Map.Entry<HRegionInfo, ServerName> e: this.regions.entrySet()) {
       if (!e.getKey().isMetaRegion() && e.getValue() != null) {
         LOG.debug("Found " + e + " out on cluster");
-        userRegionsOutOnCluster = true;
+        regionsToProcess = true;
         break;
       }
       if (nodes.contains(e.getKey().getEncodedName())) {
         LOG.debug("Found " + e + " in RITs");
-        userRegionsOutOnCluster = true;
+        // Could be a meta region.
+        regionsToProcess = true;
         break;
       }
     }
 
     // If we found user regions out on cluster, its a failover.
-    if (userRegionsOutOnCluster) {
+    if (regionsToProcess) {
       LOG.info("Found regions out on cluster or in RIT; failover");
       if (!nodes.isEmpty()) {
         for (String encodedRegionName: nodes) {

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/SplitLogWorker.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/SplitLogWorker.java?rev=1098023&r1=1098022&r2=1098023&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/SplitLogWorker.java (original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/SplitLogWorker.java Fri
Apr 29 23:25:18 2011
@@ -198,8 +198,8 @@ public class SplitLogWorker extends ZooK
           try {
             taskReadyLock.wait();
           } catch (InterruptedException e) {
-            LOG.warn("SplitLogWorker interurrpted while waiting for task," +
-                " exiting", e);
+            LOG.info("SplitLogWorker interrupted while waiting for task," +
+              " exiting: " + e.toString());
             assert exitWorker == true;
             return;
           }

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKSplitLog.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKSplitLog.java?rev=1098023&r1=1098022&r2=1098023&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKSplitLog.java (original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKSplitLog.java Fri Apr 29
23:25:18 2011
@@ -31,10 +31,8 @@ import java.util.concurrent.atomic.Atomi
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.Path;
-import org.apache.hadoop.hbase.HServerInfo;
 import org.apache.hadoop.hbase.master.SplitLogManager;
 import org.apache.hadoop.hbase.regionserver.SplitLogWorker;
 import org.apache.hadoop.hbase.util.Bytes;



Mime
View raw message