hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From te...@apache.org
Subject svn commit: r1229418 - in /hbase/trunk: CHANGES.txt src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
Date Mon, 09 Jan 2012 23:22:37 GMT
Author: tedyu
Date: Mon Jan  9 23:22:37 2012
New Revision: 1229418

URL: http://svn.apache.org/viewvc?rev=1229418&view=rev
Log:
HBASE-5152  Region is on service before completing initialization when doing rollback of split,
               it will affect read correctness (Chunhui)

Modified:
    hbase/trunk/CHANGES.txt
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java

Modified: hbase/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hbase/trunk/CHANGES.txt?rev=1229418&r1=1229417&r2=1229418&view=diff
==============================================================================
--- hbase/trunk/CHANGES.txt (original)
+++ hbase/trunk/CHANGES.txt Mon Jan  9 23:22:37 2012
@@ -473,6 +473,8 @@ Release 0.92.0 - Unreleased
    HBASE-5081  Distributed log splitting deleteNode races against splitLog retry (Prakash)
    HBASE-4357  Region stayed in transition - in closing state (Ming Ma)
    HBASE-5088  A concurrency issue on SoftValueSortedMap (Jieshan Bean and Lars H)
+   HBASE-5152  Region is on service before completing initialization when doing rollback
of split,
+               it will affect read correctness (Chunhui)
 
   TESTS
    HBASE-4450  test for number of blocks read: to serve as baseline for expected

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java?rev=1229418&r1=1229417&r2=1229418&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java (original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java Mon Jan  9
23:22:37 2012
@@ -50,7 +50,6 @@ import java.util.concurrent.atomic.Atomi
 import java.util.concurrent.atomic.AtomicLong;
 import java.util.concurrent.locks.ReentrantReadWriteLock;
 
-import com.google.common.collect.Maps;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.hadoop.conf.Configuration;
@@ -116,6 +115,7 @@ import org.cliffc.high_scale_lib.Counter
 import com.google.common.base.Preconditions;
 import com.google.common.collect.ClassToInstanceMap;
 import com.google.common.collect.Lists;
+import com.google.common.collect.Maps;
 import com.google.common.collect.MutableClassToInstanceMap;
 
 /**
@@ -513,9 +513,6 @@ public class HRegion implements HeapSize
       status.setStatus("Running coprocessor pre-open hook");
       coprocessorHost.preOpen();
     }
-    // A region can be reopened if failed a split; reset flags
-    this.closing.set(false);
-    this.closed.set(false);
 
     // Write HRI to a file in case we need to recover .META.
     status.setStatus("Writing region info on filesystem");
@@ -587,11 +584,15 @@ public class HRegion implements HeapSize
     long nextSeqid = maxSeqId + 1;
     LOG.info("Onlined " + this.toString() + "; next sequenceid=" + nextSeqid);
 
+    // A region can be reopened if failed a split; reset flags
+    this.closing.set(false);
+    this.closed.set(false);
 
     if (coprocessorHost != null) {
       status.setStatus("Running coprocessor post-open hooks");
       coprocessorHost.postOpen();
     }
+
     status.markComplete("Region opened successfully");
     return nextSeqid;
   }



Mime
View raw message