Review Board 1.7.22


HBASE-4820 Distributed log splitting coding enhancement to make it easier to understand, no semantics change

Review Request #2895 - Created Nov. 21, 2011 and submitted

Jimmy Xiang
git://git.apache.org/hbase.git
HBASE-4820
Reviewers
hbase
jonathan, tlipcon
hbase-git
Distributed log splitting coding enhancement to make it easier to understand, no semantics change.
It is some issue raised during the code review in back porting this feature to CDH.
Ran unit tests. Non-flaky tests are green. Two client tests didn't pass, which are not related to this change.
src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java
Revision 2101054 New Change
[20] 1544 lines
[+20] [+] private boolean isDisabledorDisablingRegionInRIT(final HRegionInfo region) {
1545
  int setOfflineInZooKeeper(final RegionState state,
1545
  int setOfflineInZooKeeper(final RegionState state,
1546
      boolean hijack) {
1546
      boolean hijack) {
1547
    // In case of reassignment the current state in memory need not be
1547
    // In case of reassignment the current state in memory need not be
1548
    // OFFLINE. 
1548
    // OFFLINE. 
1549
    if (!hijack && !state.isClosed() && !state.isOffline()) {
1549
    if (!hijack && !state.isClosed() && !state.isOffline()) {
1550
      this.master.abort("Unexpected state trying to OFFLINE; " + state,
1550
      String msg = "Unexpected state : " + state + " .. Cannot transit it to OFFLINE.";
1551
          new IllegalStateException());
1551
      this.master.abort(msg, new IllegalStateException(msg));
1552
      return -1;
1552
      return -1;
1553
    }
1553
    }
1554
    boolean allowZNodeCreation = false;
1554
    boolean allowZNodeCreation = false;
1555
    // Under reassignment if the current state is PENDING_OPEN
1555
    // Under reassignment if the current state is PENDING_OPEN
1556
    // or OPENING then refresh the in-memory state to PENDING_OPEN. This is
1556
    // or OPENING then refresh the in-memory state to PENDING_OPEN. This is
[+20] [20] 1407 lines
src/main/java/org/apache/hadoop/hbase/master/MasterFileSystem.java
Revision d7a648d New Change
 
src/main/java/org/apache/hadoop/hbase/master/SplitLogManager.java
Revision 7dd67e9 New Change
 
src/main/java/org/apache/hadoop/hbase/regionserver/SplitLogWorker.java
Revision 1d329b0 New Change
 
src/main/java/org/apache/hadoop/hbase/regionserver/wal/HLogSplitter.java
Revision 21747b1 New Change
 
src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java
Revision 51daa1f New Change
 
src/test/java/org/apache/hadoop/hbase/master/TestSplitLogManager.java
Revision c8684ec New Change
 
  1. src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java: Loading...
  2. src/main/java/org/apache/hadoop/hbase/master/MasterFileSystem.java: Loading...
  3. src/main/java/org/apache/hadoop/hbase/master/SplitLogManager.java: Loading...
  4. src/main/java/org/apache/hadoop/hbase/regionserver/SplitLogWorker.java: Loading...
  5. src/main/java/org/apache/hadoop/hbase/regionserver/wal/HLogSplitter.java: Loading...
  6. src/test/java/org/apache/hadoop/hbase/master/TestDistributedLogSplitting.java: Loading...
  7. src/test/java/org/apache/hadoop/hbase/master/TestSplitLogManager.java: Loading...