[1/9] hbase git commit: HBASE-21265 Split up TestRSGroups
Repository: hbase Updated Branches: refs/heads/branch-1 6e0ee4efa -> ae606c3d7 refs/heads/branch-1.4 91118ce5f -> 54d89e1a2 refs/heads/branch-2 9e3f3fdc1 -> 24d19e87e refs/heads/master 4508f670b -> e42741e08 http://git-wip-us.apache.org/repos/asf/hbase/blob/ae606c3d/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java index ac82e4c..05f41dd 100644 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java +++ b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java @@ -19,19 +19,15 @@ */ package org.apache.hadoop.hbase.rsgroup; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertNull; -import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; +import com.google.common.collect.Maps; +import com.google.common.collect.Sets; import java.io.IOException; -import java.security.SecureRandom; import java.util.HashSet; import java.util.LinkedList; import java.util.List; import java.util.Map; +import java.util.Random; import java.util.Set; import java.util.TreeMap; @@ -40,57 +36,155 @@ import org.apache.commons.logging.LogFactory; import org.apache.hadoop.hbase.ClusterStatus; import org.apache.hadoop.hbase.HBaseCluster; import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HColumnDescriptor; +import org.apache.hadoop.hbase.HConstants; import org.apache.hadoop.hbase.HRegionInfo; import org.apache.hadoop.hbase.HTableDescriptor; +import org.apache.hadoop.hbase.MiniHBaseCluster; import org.apache.hadoop.hbase.NamespaceDescriptor; import org.apache.hadoop.hbase.RegionLoad; import org.apache.hadoop.hbase.ServerName; import org.apache.hadoop.hbase.TableName; import org.apache.hadoop.hbase.Waiter; -import org.apache.hadoop.hbase.client.ClusterConnection; import org.apache.hadoop.hbase.client.HBaseAdmin; -import org.apache.hadoop.hbase.constraint.ConstraintException; +import org.apache.hadoop.hbase.coprocessor.BaseMasterObserver; +import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; +import org.apache.hadoop.hbase.coprocessor.MasterCoprocessorEnvironment; +import org.apache.hadoop.hbase.coprocessor.ObserverContext; import org.apache.hadoop.hbase.master.HMaster; -import org.apache.hadoop.hbase.master.RegionState; +import org.apache.hadoop.hbase.master.MasterCoprocessorHost; +import org.apache.hadoop.hbase.master.ServerManager; +import org.apache.hadoop.hbase.master.snapshot.SnapshotManager; import org.apache.hadoop.hbase.net.Address; -import org.apache.hadoop.hbase.protobuf.ProtobufUtil; -import org.apache.hadoop.hbase.protobuf.generated.AdminProtos; -import org.apache.hadoop.hbase.protobuf.generated.AdminProtos.GetServerInfoRequest; import org.apache.hadoop.hbase.util.Bytes; -import org.junit.Assert; -import org.junit.Test; - -import com.google.common.collect.Lists; -import com.google.common.collect.Maps; -import com.google.common.collect.Sets; - public abstract class TestRSGroupsBase { protected static final Log LOG = LogFactory.getLog(TestRSGroupsBase.class); //shared protected final static String groupPrefix = "Group"; protected final static String tablePrefix = "Group"; - protected final static SecureRandom rand = new SecureRandom(); + protected final static Random rand = new Random(); //shared, cluster type specific protected static HBaseTestingUtility TEST_UTIL; protected static HBaseAdmin admin; protected static HBaseCluster cluster; protected static RSGroupAdmin rsGroupAdmin; + protected static HMaster master; + protected static boolean init = false; + protected static RSGroupAdminEndpoint RSGroupAdminEndpoint; + protected static CPMasterObserver observer; public final static long WAIT_TIMEOUT = 6*5; public final static int NUM_SLAVES_BASE = 4; //number of slaves for the smallest cluster + public static void setUpTestBeforeClass() throws Exception { +TEST_UTIL = new HBaseTestingUtility(); +TEST_UTIL.getConfiguration().setFloat( +"hbase.master.balancer.stochastic.tableSkewCost", 6000); +TEST_UTIL.getConfiguration().set( +HConstants.HBASE_MASTER_LOADBALANCER_CLASS, +RSGroupBasedLoadBalancer.class.getName()); + TEST_UTIL.getConfiguration().set(CoprocessorHost.MASTER_COPROCESSOR_CONF_KEY, +RSGroupAdminEndpoint.class.getName() + "," + CPMasterObserver.class.getName()); +TEST_UTIL.getConfiguration().setBoolean( +HConstants.ZOOKEEPER_USEMULTI, +true); +TEST_UTIL.startMiniCluster(NUM_SLAVES_BASE - 1); +
[9/9] hbase git commit: HBASE-21265 Split up TestRSGroups
HBASE-21265 Split up TestRSGroups Signed-off-by: Ted Yu Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/54d89e1a Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/54d89e1a Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/54d89e1a Branch: refs/heads/branch-1.4 Commit: 54d89e1a2b2beda1b9c2a43003ea4bcc96d22e7f Parents: 7242650 Author: Andrew Purtell Authored: Thu Oct 4 16:37:44 2018 -0700 Committer: Andrew Purtell Committed: Thu Oct 4 16:37:44 2018 -0700 -- .../hadoop/hbase/rsgroup/TestEnableRSGroup.java | 98 -- .../hbase/rsgroup/TestEnableRSGroups.java | 98 ++ .../hadoop/hbase/rsgroup/TestRSGroups.java | 521 -- .../hbase/rsgroup/TestRSGroupsAdmin1.java | 434 .../hbase/rsgroup/TestRSGroupsAdmin2.java | 417 .../hbase/rsgroup/TestRSGroupsBalance.java | 183 .../hadoop/hbase/rsgroup/TestRSGroupsBase.java | 987 --- .../hbase/rsgroup/TestRSGroupsBasics.java | 215 .../hbase/rsgroup/TestRSGroupsKillRS.java | 141 +++ 9 files changed, 1697 insertions(+), 1397 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/54d89e1a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java deleted file mode 100644 index 45dc5d3..000 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java +++ /dev/null @@ -1,98 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.hadoop.hbase.rsgroup; - -import java.io.IOException; - -import org.apache.hadoop.conf.Configuration; -import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HConstants; -import org.apache.hadoop.hbase.Waiter; -import org.apache.hadoop.hbase.Waiter.ExplainingPredicate; -import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; -import org.apache.hadoop.hbase.testclassification.MediumTests; -import org.junit.AfterClass; -import org.junit.BeforeClass; -import org.junit.Test; -import org.junit.experimental.categories.Category; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -/** - * Test enable RSGroup - */ -@Category({ MediumTests.class }) -public class TestEnableRSGroup { - - protected static final Logger LOG = LoggerFactory.getLogger(TestEnableRSGroup.class); - - private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); - private static Configuration conf = TEST_UTIL.getConfiguration(); - - @BeforeClass - public static void setUp() throws Exception { -TEST_UTIL.startMiniCluster(); - } - - @AfterClass - public static void tearDown() throws Exception { -TEST_UTIL.shutdownMiniCluster(); - } - - @Test - public void testEnableRSGroup() throws IOException, InterruptedException { -TEST_UTIL.getMiniHBaseCluster().stopMaster(0); -LOG.info("stopped master..."); -conf.set(CoprocessorHost.MASTER_COPROCESSOR_CONF_KEY, RSGroupAdminEndpoint.class.getName()); -conf.set(HConstants.HBASE_MASTER_LOADBALANCER_CLASS, RSGroupBasedLoadBalancer.class.getName()); -TEST_UTIL.getMiniHBaseCluster().setConf(conf); - -TEST_UTIL.getMiniHBaseCluster().startMaster(); -TEST_UTIL.getMiniHBaseCluster().waitForActiveAndReadyMaster(6); -LOG.info("started master..."); - -// check if master started successfully -Waiter.waitFor(TEST_UTIL.getConfiguration(), 6, new ExplainingPredicate() { - @Override - public boolean evaluate() throws IOException { -return TEST_UTIL.getMiniHBaseCluster().getMaster() != null; - } - - @Override - public String explainFailure() throws IOException { -return "Master failed to start up"; - } -}); - -// wait RSGroupBasedLoadBalancer online -
[4/9] hbase git commit: HBASE-21265 Split up TestRSGroups
HBASE-21265 Split up TestRSGroups Signed-off-by: Ted Yu Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/e42741e0 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/e42741e0 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/e42741e0 Branch: refs/heads/master Commit: e42741e0858a59961ae0900b5ef073e16ef6126c Parents: 4508f67 Author: Andrew Purtell Authored: Wed Oct 3 16:13:09 2018 -0700 Committer: Andrew Purtell Committed: Thu Oct 4 16:24:06 2018 -0700 -- .../hadoop/hbase/rsgroup/TestEnableRSGroup.java | 95 -- .../hbase/rsgroup/TestEnableRSGroups.java | 96 ++ .../hadoop/hbase/rsgroup/TestRSGroups.java | 641 -- .../hbase/rsgroup/TestRSGroupsAdmin1.java | 502 .../hbase/rsgroup/TestRSGroupsAdmin2.java | 487 +++ .../hbase/rsgroup/TestRSGroupsBalance.java | 188 +++ .../hadoop/hbase/rsgroup/TestRSGroupsBase.java | 1202 -- .../hbase/rsgroup/TestRSGroupsBasics.java | 320 + .../hbase/rsgroup/TestRSGroupsKillRS.java | 149 +++ .../hbase/rsgroup/TestRSGroupsOfflineMode.java |1 + .../hbase/rsgroup/TestRSGroupsWithACL.java |4 +- 11 files changed, 2013 insertions(+), 1672 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/e42741e0/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java deleted file mode 100644 index 77faec7..000 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java +++ /dev/null @@ -1,95 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.hadoop.hbase.rsgroup; - -import static java.lang.Thread.sleep; -import static org.junit.Assert.assertTrue; - -import java.io.IOException; - -import org.apache.hadoop.conf.Configuration; -import org.apache.hadoop.hbase.HBaseClassTestRule; -import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HConstants; -import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; -import org.apache.hadoop.hbase.testclassification.MediumTests; -import org.junit.AfterClass; -import org.junit.BeforeClass; -import org.junit.ClassRule; -import org.junit.Test; -import org.junit.experimental.categories.Category; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -/** - * Test enable RSGroup - */ -@Category({ MediumTests.class }) -public class TestEnableRSGroup { - - @ClassRule - public static final HBaseClassTestRule CLASS_RULE = - HBaseClassTestRule.forClass(TestEnableRSGroup.class); - - protected static final Logger LOG = LoggerFactory.getLogger(TestEnableRSGroup.class); - - private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); - - @BeforeClass - public static void setUp() throws Exception { -final Configuration conf = TEST_UTIL.getConfiguration(); -conf.setBoolean(CoprocessorHost.COPROCESSORS_ENABLED_CONF_KEY, true); -TEST_UTIL.startMiniCluster(5); - } - - @AfterClass - public static void tearDown() throws Exception { -LOG.info("to stop miniCluster"); -TEST_UTIL.shutdownMiniCluster(); - } - - @Test - public void testEnableRSGroup() throws IOException, InterruptedException { -TEST_UTIL.getMiniHBaseCluster().stopMaster(0); -TEST_UTIL.getMiniHBaseCluster().waitOnMaster(0); - -LOG.info("stopped master..."); -final Configuration conf = TEST_UTIL.getMiniHBaseCluster().getConfiguration(); -conf.set(CoprocessorHost.MASTER_COPROCESSOR_CONF_KEY, RSGroupAdminEndpoint.class.getName()); -conf.set(HConstants.HBASE_MASTER_LOADBALANCER_CLASS, RSGroupBasedLoadBalancer.class.getName()); - -TEST_UTIL.getMiniHBaseCluster().startMaster(); -TEST_UTIL.getMiniHBaseCluster().waitForActiveAndReadyMaster(6); -
[3/9] hbase git commit: HBASE-21265 Split up TestRSGroups
http://git-wip-us.apache.org/repos/asf/hbase/blob/e42741e0/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java index 43099db..6a70b30 100644 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java +++ b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java @@ -17,67 +17,61 @@ */ package org.apache.hadoop.hbase.rsgroup; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNull; import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; import java.io.IOException; -import java.security.SecureRandom; -import java.util.ArrayList; import java.util.EnumSet; import java.util.HashSet; -import java.util.Iterator; import java.util.LinkedList; import java.util.List; import java.util.Map; +import java.util.Optional; +import java.util.Random; import java.util.Set; import java.util.TreeMap; + import org.apache.hadoop.hbase.ClusterMetrics; import org.apache.hadoop.hbase.ClusterMetrics.Option; import org.apache.hadoop.hbase.HBaseCluster; import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HColumnDescriptor; -import org.apache.hadoop.hbase.HTableDescriptor; +import org.apache.hadoop.hbase.HConstants; +import org.apache.hadoop.hbase.MiniHBaseCluster; import org.apache.hadoop.hbase.NamespaceDescriptor; import org.apache.hadoop.hbase.RegionMetrics; import org.apache.hadoop.hbase.ServerMetrics; import org.apache.hadoop.hbase.ServerName; import org.apache.hadoop.hbase.TableName; -import org.apache.hadoop.hbase.TableNotFoundException; import org.apache.hadoop.hbase.Waiter; import org.apache.hadoop.hbase.client.Admin; -import org.apache.hadoop.hbase.client.ClusterConnection; import org.apache.hadoop.hbase.client.RegionInfo; -import org.apache.hadoop.hbase.constraint.ConstraintException; +import org.apache.hadoop.hbase.client.TableDescriptor; +import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; +import org.apache.hadoop.hbase.coprocessor.MasterCoprocessor; +import org.apache.hadoop.hbase.coprocessor.MasterCoprocessorEnvironment; +import org.apache.hadoop.hbase.coprocessor.MasterObserver; +import org.apache.hadoop.hbase.coprocessor.ObserverContext; import org.apache.hadoop.hbase.master.HMaster; +import org.apache.hadoop.hbase.master.MasterCoprocessorHost; +import org.apache.hadoop.hbase.master.ServerManager; +import org.apache.hadoop.hbase.master.snapshot.SnapshotManager; import org.apache.hadoop.hbase.net.Address; import org.apache.hadoop.hbase.util.Bytes; -import org.junit.Assert; -import org.junit.Before; + import org.junit.Rule; -import org.junit.Test; import org.junit.rules.TestName; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import org.apache.hbase.thirdparty.com.google.common.collect.Lists; import org.apache.hbase.thirdparty.com.google.common.collect.Maps; import org.apache.hbase.thirdparty.com.google.common.collect.Sets; -import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; -import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos; -import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.GetServerInfoRequest; public abstract class TestRSGroupsBase { protected static final Logger LOG = LoggerFactory.getLogger(TestRSGroupsBase.class); - @Rule - public TestName name = new TestName(); //shared protected final static String groupPrefix = "Group"; protected final static String tablePrefix = "Group"; - protected final static SecureRandom rand = new SecureRandom(); + protected final static Random rand = new Random(); //shared, cluster type specific protected static HBaseTestingUtility TEST_UTIL; @@ -85,26 +79,115 @@ public abstract class TestRSGroupsBase { protected static HBaseCluster cluster; protected static RSGroupAdmin rsGroupAdmin; protected static HMaster master; + protected static boolean INIT = false; + protected static RSGroupAdminEndpoint rsGroupAdminEndpoint; + protected static CPMasterObserver observer; public final static long WAIT_TIMEOUT = 6*5; public final static int NUM_SLAVES_BASE = 4; //number of slaves for the smallest cluster public static int NUM_DEAD_SERVERS = 0; // Per test variables - TableName tableName; - @Before - public void setup() { + @Rule + public TestName name = new TestName(); + protected TableName tableName; + + public static void setUpTestBeforeClass() throws Exception { +TEST_UTIL = new HBaseTestingUtility(); +TEST_UTIL.getConfiguration().setFloat( +"hbase.master.balancer.stochastic.tableSkewCost", 6000); +TEST_UTIL.getConfiguration().set(
[8/9] hbase git commit: HBASE-21265 Split up TestRSGroups
http://git-wip-us.apache.org/repos/asf/hbase/blob/54d89e1a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java index ac82e4c..05f41dd 100644 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java +++ b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java @@ -19,19 +19,15 @@ */ package org.apache.hadoop.hbase.rsgroup; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertNull; -import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; +import com.google.common.collect.Maps; +import com.google.common.collect.Sets; import java.io.IOException; -import java.security.SecureRandom; import java.util.HashSet; import java.util.LinkedList; import java.util.List; import java.util.Map; +import java.util.Random; import java.util.Set; import java.util.TreeMap; @@ -40,57 +36,155 @@ import org.apache.commons.logging.LogFactory; import org.apache.hadoop.hbase.ClusterStatus; import org.apache.hadoop.hbase.HBaseCluster; import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HColumnDescriptor; +import org.apache.hadoop.hbase.HConstants; import org.apache.hadoop.hbase.HRegionInfo; import org.apache.hadoop.hbase.HTableDescriptor; +import org.apache.hadoop.hbase.MiniHBaseCluster; import org.apache.hadoop.hbase.NamespaceDescriptor; import org.apache.hadoop.hbase.RegionLoad; import org.apache.hadoop.hbase.ServerName; import org.apache.hadoop.hbase.TableName; import org.apache.hadoop.hbase.Waiter; -import org.apache.hadoop.hbase.client.ClusterConnection; import org.apache.hadoop.hbase.client.HBaseAdmin; -import org.apache.hadoop.hbase.constraint.ConstraintException; +import org.apache.hadoop.hbase.coprocessor.BaseMasterObserver; +import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; +import org.apache.hadoop.hbase.coprocessor.MasterCoprocessorEnvironment; +import org.apache.hadoop.hbase.coprocessor.ObserverContext; import org.apache.hadoop.hbase.master.HMaster; -import org.apache.hadoop.hbase.master.RegionState; +import org.apache.hadoop.hbase.master.MasterCoprocessorHost; +import org.apache.hadoop.hbase.master.ServerManager; +import org.apache.hadoop.hbase.master.snapshot.SnapshotManager; import org.apache.hadoop.hbase.net.Address; -import org.apache.hadoop.hbase.protobuf.ProtobufUtil; -import org.apache.hadoop.hbase.protobuf.generated.AdminProtos; -import org.apache.hadoop.hbase.protobuf.generated.AdminProtos.GetServerInfoRequest; import org.apache.hadoop.hbase.util.Bytes; -import org.junit.Assert; -import org.junit.Test; - -import com.google.common.collect.Lists; -import com.google.common.collect.Maps; -import com.google.common.collect.Sets; - public abstract class TestRSGroupsBase { protected static final Log LOG = LogFactory.getLog(TestRSGroupsBase.class); //shared protected final static String groupPrefix = "Group"; protected final static String tablePrefix = "Group"; - protected final static SecureRandom rand = new SecureRandom(); + protected final static Random rand = new Random(); //shared, cluster type specific protected static HBaseTestingUtility TEST_UTIL; protected static HBaseAdmin admin; protected static HBaseCluster cluster; protected static RSGroupAdmin rsGroupAdmin; + protected static HMaster master; + protected static boolean init = false; + protected static RSGroupAdminEndpoint RSGroupAdminEndpoint; + protected static CPMasterObserver observer; public final static long WAIT_TIMEOUT = 6*5; public final static int NUM_SLAVES_BASE = 4; //number of slaves for the smallest cluster + public static void setUpTestBeforeClass() throws Exception { +TEST_UTIL = new HBaseTestingUtility(); +TEST_UTIL.getConfiguration().setFloat( +"hbase.master.balancer.stochastic.tableSkewCost", 6000); +TEST_UTIL.getConfiguration().set( +HConstants.HBASE_MASTER_LOADBALANCER_CLASS, +RSGroupBasedLoadBalancer.class.getName()); + TEST_UTIL.getConfiguration().set(CoprocessorHost.MASTER_COPROCESSOR_CONF_KEY, +RSGroupAdminEndpoint.class.getName() + "," + CPMasterObserver.class.getName()); +TEST_UTIL.getConfiguration().setBoolean( +HConstants.ZOOKEEPER_USEMULTI, +true); +TEST_UTIL.startMiniCluster(NUM_SLAVES_BASE - 1); +TEST_UTIL.getConfiguration().setInt( +ServerManager.WAIT_ON_REGIONSERVERS_MINTOSTART, +NUM_SLAVES_BASE - 1); + TEST_UTIL.getConfiguration().setBoolean(SnapshotManager.HBASE_SNAPSHOT_ENABLED, true); +initialize(); + } + +
[7/9] hbase git commit: Set version on branch to 1.4.9-SNAPSHOT
Set version on branch to 1.4.9-SNAPSHOT Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/7242650a Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/7242650a Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/7242650a Branch: refs/heads/branch-1.4 Commit: 7242650afd466df511ba2d4cfa34f6d082cb1004 Parents: 91118ce Author: Andrew Purtell Authored: Thu Oct 4 16:37:20 2018 -0700 Committer: Andrew Purtell Committed: Thu Oct 4 16:37:40 2018 -0700 -- hbase-annotations/pom.xml| 2 +- hbase-archetypes/hbase-archetype-builder/pom.xml | 2 +- hbase-archetypes/hbase-client-project/pom.xml| 2 +- hbase-archetypes/hbase-shaded-client-project/pom.xml | 2 +- hbase-archetypes/pom.xml | 2 +- hbase-assembly/pom.xml | 2 +- hbase-checkstyle/pom.xml | 4 ++-- hbase-client/pom.xml | 2 +- hbase-common/pom.xml | 2 +- hbase-error-prone/pom.xml| 4 ++-- hbase-examples/pom.xml | 2 +- hbase-external-blockcache/pom.xml| 2 +- hbase-hadoop-compat/pom.xml | 2 +- hbase-hadoop2-compat/pom.xml | 2 +- hbase-it/pom.xml | 2 +- hbase-metrics-api/pom.xml| 2 +- hbase-metrics/pom.xml| 2 +- hbase-prefix-tree/pom.xml| 2 +- hbase-procedure/pom.xml | 2 +- hbase-protocol/pom.xml | 2 +- hbase-resource-bundle/pom.xml| 2 +- hbase-rest/pom.xml | 2 +- hbase-rsgroup/pom.xml| 2 +- hbase-server/pom.xml | 2 +- hbase-shaded/hbase-shaded-check-invariants/pom.xml | 2 +- hbase-shaded/hbase-shaded-client/pom.xml | 2 +- hbase-shaded/hbase-shaded-server/pom.xml | 2 +- hbase-shaded/pom.xml | 2 +- hbase-shell/pom.xml | 2 +- hbase-testing-util/pom.xml | 2 +- hbase-thrift/pom.xml | 2 +- pom.xml | 2 +- 32 files changed, 34 insertions(+), 34 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/7242650a/hbase-annotations/pom.xml -- diff --git a/hbase-annotations/pom.xml b/hbase-annotations/pom.xml index ddaad3d..7ec7ef9 100644 --- a/hbase-annotations/pom.xml +++ b/hbase-annotations/pom.xml @@ -23,7 +23,7 @@ hbase org.apache.hbase -1.4.8 +1.4.9-SNAPSHOT .. http://git-wip-us.apache.org/repos/asf/hbase/blob/7242650a/hbase-archetypes/hbase-archetype-builder/pom.xml -- diff --git a/hbase-archetypes/hbase-archetype-builder/pom.xml b/hbase-archetypes/hbase-archetype-builder/pom.xml index 6ed43c9..3743e35 100644 --- a/hbase-archetypes/hbase-archetype-builder/pom.xml +++ b/hbase-archetypes/hbase-archetype-builder/pom.xml @@ -25,7 +25,7 @@ hbase-archetypes org.apache.hbase -1.4.8 +1.4.9-SNAPSHOT .. http://git-wip-us.apache.org/repos/asf/hbase/blob/7242650a/hbase-archetypes/hbase-client-project/pom.xml -- diff --git a/hbase-archetypes/hbase-client-project/pom.xml b/hbase-archetypes/hbase-client-project/pom.xml index 4dbc2a9..4b2f0f4 100644 --- a/hbase-archetypes/hbase-client-project/pom.xml +++ b/hbase-archetypes/hbase-client-project/pom.xml @@ -26,7 +26,7 @@ hbase-archetypes org.apache.hbase -1.4.8 +1.4.9-SNAPSHOT .. hbase-client-project http://git-wip-us.apache.org/repos/asf/hbase/blob/7242650a/hbase-archetypes/hbase-shaded-client-project/pom.xml -- diff --git a/hbase-archetypes/hbase-shaded-client-project/pom.xml b/hbase-archetypes/hbase-shaded-client-project/pom.xml index 6693bd7..7616d94 100644 --- a/hbase-archetypes/hbase-shaded-client-project/pom.xml +++ b/hbase-archetypes/hbase-shaded-client-project/pom.xml @@ -26,7 +26,7 @@ hbase-archetypes org.apache.hbase -1.4.8 +1.4.9-SNAPSHOT .. hbase-shaded-client-project http://git-wip-us.apache.org/repos/asf/hbase/blob/7242650a/hbase-archetypes/pom.xml -- diff --git a/hbase-archetypes/pom.xml
[5/9] hbase git commit: HBASE-21265 Split up TestRSGroups
http://git-wip-us.apache.org/repos/asf/hbase/blob/24d19e87/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java index 386dcf3..fdefe47 100644 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java +++ b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java @@ -17,29 +17,25 @@ */ package org.apache.hadoop.hbase.rsgroup; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNull; import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; import java.io.IOException; -import java.security.SecureRandom; -import java.util.ArrayList; import java.util.EnumSet; import java.util.HashSet; -import java.util.Iterator; import java.util.LinkedList; import java.util.List; import java.util.Map; +import java.util.Optional; +import java.util.Random; import java.util.Set; import java.util.TreeMap; + import org.apache.hadoop.hbase.ClusterMetrics; import org.apache.hadoop.hbase.ClusterMetrics.Option; import org.apache.hadoop.hbase.HBaseCluster; import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HColumnDescriptor; -import org.apache.hadoop.hbase.HTableDescriptor; +import org.apache.hadoop.hbase.HConstants; +import org.apache.hadoop.hbase.MiniHBaseCluster; import org.apache.hadoop.hbase.NamespaceDescriptor; import org.apache.hadoop.hbase.RegionMetrics; import org.apache.hadoop.hbase.ServerMetrics; @@ -47,36 +43,35 @@ import org.apache.hadoop.hbase.ServerName; import org.apache.hadoop.hbase.TableName; import org.apache.hadoop.hbase.Waiter; import org.apache.hadoop.hbase.client.Admin; -import org.apache.hadoop.hbase.client.ClusterConnection; import org.apache.hadoop.hbase.client.RegionInfo; -import org.apache.hadoop.hbase.constraint.ConstraintException; +import org.apache.hadoop.hbase.client.TableDescriptor; +import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; +import org.apache.hadoop.hbase.coprocessor.MasterCoprocessor; +import org.apache.hadoop.hbase.coprocessor.MasterCoprocessorEnvironment; +import org.apache.hadoop.hbase.coprocessor.MasterObserver; +import org.apache.hadoop.hbase.coprocessor.ObserverContext; import org.apache.hadoop.hbase.master.HMaster; +import org.apache.hadoop.hbase.master.MasterCoprocessorHost; +import org.apache.hadoop.hbase.master.ServerManager; +import org.apache.hadoop.hbase.master.snapshot.SnapshotManager; import org.apache.hadoop.hbase.net.Address; import org.apache.hadoop.hbase.util.Bytes; -import org.junit.Assert; -import org.junit.Before; + import org.junit.Rule; -import org.junit.Test; import org.junit.rules.TestName; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import org.apache.hbase.thirdparty.com.google.common.collect.Lists; import org.apache.hbase.thirdparty.com.google.common.collect.Maps; import org.apache.hbase.thirdparty.com.google.common.collect.Sets; -import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; -import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos; -import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos.GetServerInfoRequest; public abstract class TestRSGroupsBase { protected static final Logger LOG = LoggerFactory.getLogger(TestRSGroupsBase.class); - @Rule - public TestName name = new TestName(); //shared protected final static String groupPrefix = "Group"; protected final static String tablePrefix = "Group"; - protected final static SecureRandom rand = new SecureRandom(); + protected final static Random rand = new Random(); //shared, cluster type specific protected static HBaseTestingUtility TEST_UTIL; @@ -84,26 +79,115 @@ public abstract class TestRSGroupsBase { protected static HBaseCluster cluster; protected static RSGroupAdmin rsGroupAdmin; protected static HMaster master; + protected static boolean INIT = false; + protected static RSGroupAdminEndpoint rsGroupAdminEndpoint; + protected static CPMasterObserver observer; public final static long WAIT_TIMEOUT = 6*5; public final static int NUM_SLAVES_BASE = 4; //number of slaves for the smallest cluster public static int NUM_DEAD_SERVERS = 0; // Per test variables - TableName tableName; - @Before - public void setup() { + @Rule + public TestName name = new TestName(); + protected TableName tableName; + + public static void setUpTestBeforeClass() throws Exception { +TEST_UTIL = new HBaseTestingUtility(); +TEST_UTIL.getConfiguration().setFloat( +"hbase.master.balancer.stochastic.tableSkewCost", 6000); +TEST_UTIL.getConfiguration().set( +
[2/9] hbase git commit: HBASE-21265 Split up TestRSGroups
HBASE-21265 Split up TestRSGroups Signed-off-by: Ted Yu Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/ae606c3d Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/ae606c3d Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/ae606c3d Branch: refs/heads/branch-1 Commit: ae606c3d7a7f15a7fc2515f07b884c67a7ea37bd Parents: 6e0ee4e Author: Andrew Purtell Authored: Wed Oct 3 16:13:09 2018 -0700 Committer: Andrew Purtell Committed: Thu Oct 4 14:13:38 2018 -0700 -- .../hadoop/hbase/rsgroup/TestEnableRSGroup.java | 98 -- .../hbase/rsgroup/TestEnableRSGroups.java | 98 ++ .../hadoop/hbase/rsgroup/TestRSGroups.java | 521 -- .../hbase/rsgroup/TestRSGroupsAdmin1.java | 434 .../hbase/rsgroup/TestRSGroupsAdmin2.java | 417 .../hbase/rsgroup/TestRSGroupsBalance.java | 183 .../hadoop/hbase/rsgroup/TestRSGroupsBase.java | 987 --- .../hbase/rsgroup/TestRSGroupsBasics.java | 215 .../hbase/rsgroup/TestRSGroupsKillRS.java | 141 +++ 9 files changed, 1697 insertions(+), 1397 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/ae606c3d/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java deleted file mode 100644 index 45dc5d3..000 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java +++ /dev/null @@ -1,98 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.hadoop.hbase.rsgroup; - -import java.io.IOException; - -import org.apache.hadoop.conf.Configuration; -import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HConstants; -import org.apache.hadoop.hbase.Waiter; -import org.apache.hadoop.hbase.Waiter.ExplainingPredicate; -import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; -import org.apache.hadoop.hbase.testclassification.MediumTests; -import org.junit.AfterClass; -import org.junit.BeforeClass; -import org.junit.Test; -import org.junit.experimental.categories.Category; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -/** - * Test enable RSGroup - */ -@Category({ MediumTests.class }) -public class TestEnableRSGroup { - - protected static final Logger LOG = LoggerFactory.getLogger(TestEnableRSGroup.class); - - private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); - private static Configuration conf = TEST_UTIL.getConfiguration(); - - @BeforeClass - public static void setUp() throws Exception { -TEST_UTIL.startMiniCluster(); - } - - @AfterClass - public static void tearDown() throws Exception { -TEST_UTIL.shutdownMiniCluster(); - } - - @Test - public void testEnableRSGroup() throws IOException, InterruptedException { -TEST_UTIL.getMiniHBaseCluster().stopMaster(0); -LOG.info("stopped master..."); -conf.set(CoprocessorHost.MASTER_COPROCESSOR_CONF_KEY, RSGroupAdminEndpoint.class.getName()); -conf.set(HConstants.HBASE_MASTER_LOADBALANCER_CLASS, RSGroupBasedLoadBalancer.class.getName()); -TEST_UTIL.getMiniHBaseCluster().setConf(conf); - -TEST_UTIL.getMiniHBaseCluster().startMaster(); -TEST_UTIL.getMiniHBaseCluster().waitForActiveAndReadyMaster(6); -LOG.info("started master..."); - -// check if master started successfully -Waiter.waitFor(TEST_UTIL.getConfiguration(), 6, new ExplainingPredicate() { - @Override - public boolean evaluate() throws IOException { -return TEST_UTIL.getMiniHBaseCluster().getMaster() != null; - } - - @Override - public String explainFailure() throws IOException { -return "Master failed to start up"; - } -}); - -// wait RSGroupBasedLoadBalancer online -
[6/9] hbase git commit: HBASE-21265 Split up TestRSGroups
HBASE-21265 Split up TestRSGroups Signed-off-by: Ted Yu Conflicts: hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroups.java hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsAdmin1.java hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestRSGroupsBase.java Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/24d19e87 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/24d19e87 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/24d19e87 Branch: refs/heads/branch-2 Commit: 24d19e87e0af9621f8e2f0d3940ba254fb2432a1 Parents: 9e3f3fd Author: Andrew Purtell Authored: Wed Oct 3 16:13:09 2018 -0700 Committer: Andrew Purtell Committed: Thu Oct 4 16:24:28 2018 -0700 -- .../hadoop/hbase/rsgroup/TestEnableRSGroup.java | 95 -- .../hbase/rsgroup/TestEnableRSGroups.java | 96 ++ .../hadoop/hbase/rsgroup/TestRSGroups.java | 547 - .../hbase/rsgroup/TestRSGroupsAdmin1.java | 441 +++ .../hbase/rsgroup/TestRSGroupsAdmin2.java | 487 .../hbase/rsgroup/TestRSGroupsBalance.java | 188 +++ .../hadoop/hbase/rsgroup/TestRSGroupsBase.java | 1126 -- .../hbase/rsgroup/TestRSGroupsBasics.java | 320 + .../hbase/rsgroup/TestRSGroupsKillRS.java | 149 +++ .../hbase/rsgroup/TestRSGroupsOfflineMode.java |1 + .../hbase/rsgroup/TestRSGroupsWithACL.java |4 +- 11 files changed, 1899 insertions(+), 1555 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/24d19e87/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java -- diff --git a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java b/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java deleted file mode 100644 index 77faec7..000 --- a/hbase-rsgroup/src/test/java/org/apache/hadoop/hbase/rsgroup/TestEnableRSGroup.java +++ /dev/null @@ -1,95 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.hadoop.hbase.rsgroup; - -import static java.lang.Thread.sleep; -import static org.junit.Assert.assertTrue; - -import java.io.IOException; - -import org.apache.hadoop.conf.Configuration; -import org.apache.hadoop.hbase.HBaseClassTestRule; -import org.apache.hadoop.hbase.HBaseTestingUtility; -import org.apache.hadoop.hbase.HConstants; -import org.apache.hadoop.hbase.coprocessor.CoprocessorHost; -import org.apache.hadoop.hbase.testclassification.MediumTests; -import org.junit.AfterClass; -import org.junit.BeforeClass; -import org.junit.ClassRule; -import org.junit.Test; -import org.junit.experimental.categories.Category; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -/** - * Test enable RSGroup - */ -@Category({ MediumTests.class }) -public class TestEnableRSGroup { - - @ClassRule - public static final HBaseClassTestRule CLASS_RULE = - HBaseClassTestRule.forClass(TestEnableRSGroup.class); - - protected static final Logger LOG = LoggerFactory.getLogger(TestEnableRSGroup.class); - - private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); - - @BeforeClass - public static void setUp() throws Exception { -final Configuration conf = TEST_UTIL.getConfiguration(); -conf.setBoolean(CoprocessorHost.COPROCESSORS_ENABLED_CONF_KEY, true); -TEST_UTIL.startMiniCluster(5); - } - - @AfterClass - public static void tearDown() throws Exception { -LOG.info("to stop miniCluster"); -TEST_UTIL.shutdownMiniCluster(); - } - - @Test - public void testEnableRSGroup() throws IOException, InterruptedException { -TEST_UTIL.getMiniHBaseCluster().stopMaster(0); -TEST_UTIL.getMiniHBaseCluster().waitOnMaster(0); - -LOG.info("stopped master..."); -final Configuration conf = TEST_UTIL.getMiniHBaseCluster().getConfiguration(); -conf.set(CoprocessorHost.MASTER_COPROCESSOR_CONF_KEY,
hbase git commit: HBASE-21242 [amv2] Miscellaneous minor log and assign procedure create improvements
Repository: hbase Updated Branches: refs/heads/branch-2.1 8fc90a23a -> 9d34b4581 HBASE-21242 [amv2] Miscellaneous minor log and assign procedure create improvements For RIT Duration, do better than print ms/seconds. Remove redundant UI column dedicated to duration when we log it in the status field too. Make bypass log at INFO level. Make it so on complete of subprocedure, we note count of outstanding siblings so we have a clue how much further the parent has to go before it is done (Helpful when hundreds of servers doing SCP). Have the SCP run the AP preflight check before creating an AP; saves creation of thousands of APs during fixup. Don't log tablename three times when reporting remote call failed. If lock is held already, note who has it. Also log after we get lock or if we have to wait rather than log on entrance though we may later have to wait (or we may have just picked up the lock). Signed-off-by: Mike Drob Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/9d34b458 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/9d34b458 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/9d34b458 Branch: refs/heads/branch-2.1 Commit: 9d34b4581c485deb3a659c7a435d557494e61462 Parents: 8fc90a2 Author: Michael Stack Authored: Wed Sep 26 21:22:46 2018 -0700 Committer: Michael Stack Committed: Thu Oct 4 17:18:13 2018 -0700 -- .../apache/hadoop/hbase/master/RegionState.java | 6 +-- .../hadoop/hbase/procedure2/Procedure.java | 3 ++ .../hbase/procedure2/ProcedureExecutor.java | 30 +-- .../master/AssignmentManagerStatusTmpl.jamon| 3 +- .../master/assignment/AssignProcedure.java | 40 .../assignment/RegionTransitionProcedure.java | 3 +- .../master/assignment/UnassignProcedure.java| 2 +- .../procedure/MasterProcedureScheduler.java | 5 ++- .../master/procedure/ServerCrashProcedure.java | 8 9 files changed, 73 insertions(+), 27 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/9d34b458/hbase-client/src/main/java/org/apache/hadoop/hbase/master/RegionState.java -- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/master/RegionState.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/master/RegionState.java index 7289ce8..a1e2ca6 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/master/RegionState.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/master/RegionState.java @@ -371,9 +371,9 @@ public class RegionState { public String toDescriptiveString() { long relTime = System.currentTimeMillis() - stamp; return hri.getRegionNameAsString() - + " state=" + state - + ", ts=" + new Date(stamp) + " (" + (relTime/1000) + "s ago)" - + ", server=" + serverName; + + " state=" + state + ", ts=" + new Date(stamp) + " (" + +java.time.Duration.ofMillis(relTime).toString() + +" ago), server=" + serverName; } /** http://git-wip-us.apache.org/repos/asf/hbase/blob/9d34b458/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/Procedure.java -- diff --git a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/Procedure.java b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/Procedure.java index 2b66961..01dc1be 100644 --- a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/Procedure.java +++ b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/Procedure.java @@ -883,6 +883,9 @@ public abstract class Procedure implements Comparable 0; } + /** + * @return Count of children outstanding (Badly named). + */ protected synchronized int getChildrenLatch() { return childrenLatch; } http://git-wip-us.apache.org/repos/asf/hbase/blob/9d34b458/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/ProcedureExecutor.java -- diff --git a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/ProcedureExecutor.java b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/ProcedureExecutor.java index 58e0610..cb191aa 100644 --- a/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/ProcedureExecutor.java +++ b/hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/ProcedureExecutor.java @@ -1015,21 +1015,21 @@ public class ProcedureExecutor { return false; } -LOG.debug("Begin bypass {} with lockWait={}, override={}, recursive={}", +LOG.info("Begin bypass {} with lockWait={}, override={}, recursive={}", procedure, lockWait, override, recursive);
hbase git commit: HBASE-21213 [hbck2] bypass leaves behind state in RegionStates when assign/unassign
Repository: hbase Updated Branches: refs/heads/branch-2.1 b0ac1c6ab -> 8fc90a23a HBASE-21213 [hbck2] bypass leaves behind state in RegionStates when assign/unassign Adds override to assigns and unassigns. Changes bypass 'force' to align calling the param 'override' instead. Adds recursive to 'bypass', a means of calling bypass on parent and its subprocedures (usually bypass works on leaf nodes rippling the bypass up to parent -- recursive has us work in the opposite direction): EXPERIMENTAL. bypass on an assign/unassign leaves region in RIT and the RegionStateNode loaded with the bypassed procedure. First implementation had assign/unassign cleanup leftover state. Second implementation, on feedback, keeps the state in place as a fence against other Procedures assuming the region entity, and instead adds an 'override' function that hbck2 can set on assigns/unassigns to override the fencing. Note that the below also converts ProcedureExceptions that come out of the Pv2 system into DoNotRetryIOEs. It is a little awkward because DNRIOE is in client-module, not in procedure module. Previous, we'd just keep retrying the bypass, etc. M hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/Procedure.java Have bypass take an environment like all other methods so subclasses. Fix javadoc issues. M hbase-procedure/src/main/java/org/apache/hadoop/hbase/procedure2/ProcedureExecutor.java Javadoc issues. Pass environment when we invoke bypass. M hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java Rename waitUntilNamespace... etc. to align with how these method types are named elsehwere .. i.e. waitFor rather than waitUntil.. M hbase-server/src/main/java/org/apache/hadoop/hbase/master/assignment/RegionTransitionProcedure.java Cleanup message we emit when we find an exisitng procedure working against this entity. Add support for a force function which allows Assigns/Unassigns force ownership of the Region entity. A hbase-server/src/test/java/org/apache/hadoop/hbase/master/assignment/TestRegionBypass.java Test bypass and force. M hbase-shell/src/main/ruby/shell/commands/list_procedures.rb Minor cleanup of the json output... do iso8601 timestamps. Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/8fc90a23 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/8fc90a23 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/8fc90a23 Branch: refs/heads/branch-2.1 Commit: 8fc90a23ae1a2cc73e3bba470339124bf0189fb1 Parents: b0ac1c6 Author: Michael Stack Authored: Thu Sep 20 16:53:58 2018 -0700 Committer: Michael Stack Committed: Thu Oct 4 16:37:37 2018 -0700 -- .../apache/hadoop/hbase/client/HBaseHbck.java | 15 +- .../org/apache/hadoop/hbase/client/Hbck.java| 35 +++- .../hbase/shaded/protobuf/RequestConverter.java | 10 +- .../hadoop/hbase/procedure2/Procedure.java | 29 +-- .../hbase/procedure2/ProcedureExecutor.java | 58 -- .../hadoop/hbase/procedure2/ProcedureUtil.java | 2 +- .../procedure2/RemoteProcedureException.java| 6 +- .../hbase/procedure2/TestProcedureBypass.java | 23 ++- .../src/main/protobuf/Master.proto | 6 +- .../src/main/protobuf/MasterProcedure.proto | 2 + .../hbase/rsgroup/RSGroupInfoManagerImpl.java | 3 +- .../balancer/TestRSGroupBasedLoadBalancer.java | 3 + .../org/apache/hadoop/hbase/master/HMaster.java | 8 +- .../hadoop/hbase/master/MasterRpcServices.java | 25 +-- .../master/assignment/AssignProcedure.java | 14 +- .../master/assignment/AssignmentManager.java| 27 ++- .../assignment/RegionTransitionProcedure.java | 78 ++-- .../master/assignment/UnassignProcedure.java| 14 +- .../hbase/master/balancer/BaseLoadBalancer.java | 13 +- .../master/procedure/MasterProcedureUtil.java | 16 ++ .../master/procedure/ProcedureDescriber.java| 3 +- .../master/procedure/ProcedurePrepareLatch.java | 2 +- .../master/procedure/ProcedureSyncWait.java | 5 +- .../hadoop/hbase/TestMetaTableAccessor.java | 4 +- .../apache/hadoop/hbase/client/TestHbck.java| 3 +- .../master/assignment/TestRegionBypass.java | 181 +++ .../main/ruby/shell/commands/list_procedures.rb | 7 +- .../apache/hadoop/hbase/client/TestShell.java | 1 - hbase-shell/src/test/ruby/shell/shell_test.rb | 6 +- 29 files changed, 478 insertions(+), 121 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/8fc90a23/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseHbck.java -- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseHbck.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseHbck.java index
hbase git commit: HBASE-20506 Add doc and test for unused RetryCounter, useful-looking utility
Repository: hbase Updated Branches: refs/heads/branch-2.0 7b7888e1c -> 485e02738 HBASE-20506 Add doc and test for unused RetryCounter, useful-looking utility Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/485e0273 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/485e0273 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/485e0273 Branch: refs/heads/branch-2.0 Commit: 485e0273812cfd72491eea1983dd2676774f5bb8 Parents: 7b7888e Author: Michael Stack Authored: Sun Apr 29 21:51:05 2018 -0700 Committer: Michael Stack Committed: Thu Oct 4 16:35:31 2018 -0700 -- .../apache/hadoop/hbase/util/RetryCounter.java | 26 +++-- .../hadoop/hbase/util/TestRetryCounter.java | 55 2 files changed, 76 insertions(+), 5 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/485e0273/hbase-common/src/main/java/org/apache/hadoop/hbase/util/RetryCounter.java -- diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/util/RetryCounter.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/util/RetryCounter.java index ffcd9ca..4c163fd 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/util/RetryCounter.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/util/RetryCounter.java @@ -24,9 +24,17 @@ import org.apache.yetus.audience.InterfaceAudience; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +/** + * Operation retry accounting. + * Use to calculate wait period, {@link #getBackoffTimeAndIncrementAttempts()}}, or for performing + * wait, {@link #sleepUntilNextRetry()}, in accordance with a {@link RetryConfig}, initial + * settings, and a Retry Policy, (See org.apache.hadoop.io.retry.RetryPolicy). + * Like https://github.com/rholder/guava-retrying>guava-retrying. + * @since 0.92.0 + * @see RetryCounterFactory + */ @InterfaceAudience.Private public class RetryCounter { - /** * Configuration for a retry counter */ @@ -151,10 +159,8 @@ public class RetryCounter { */ public void sleepUntilNextRetry() throws InterruptedException { int attempts = getAttemptTimes(); -long sleepTime = retryConfig.backoffPolicy.getBackoffTime(retryConfig, attempts); -if (LOG.isTraceEnabled()) { - LOG.trace("Sleeping " + sleepTime + "ms before retry #" + attempts + "..."); -} +long sleepTime = getBackoffTime(); +LOG.trace("Sleeping {} ms before retry #{}...", sleepTime, attempts); retryConfig.getTimeUnit().sleep(sleepTime); useRetry(); } @@ -174,4 +180,14 @@ public class RetryCounter { public int getAttemptTimes() { return attempts; } + + public long getBackoffTime() { +return this.retryConfig.backoffPolicy.getBackoffTime(this.retryConfig, getAttemptTimes()); + } + + public long getBackoffTimeAndIncrementAttempts() { +long backoffTime = getBackoffTime(); +useRetry(); +return backoffTime; + } } http://git-wip-us.apache.org/repos/asf/hbase/blob/485e0273/hbase-common/src/test/java/org/apache/hadoop/hbase/util/TestRetryCounter.java -- diff --git a/hbase-common/src/test/java/org/apache/hadoop/hbase/util/TestRetryCounter.java b/hbase-common/src/test/java/org/apache/hadoop/hbase/util/TestRetryCounter.java new file mode 100644 index 000..c0706b7 --- /dev/null +++ b/hbase-common/src/test/java/org/apache/hadoop/hbase/util/TestRetryCounter.java @@ -0,0 +1,55 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.hadoop.hbase.util; + +import static junit.framework.TestCase.assertTrue; + +import org.apache.hadoop.hbase.HBaseClassTestRule; +import org.apache.hadoop.hbase.testclassification.MiscTests; +import org.apache.hadoop.hbase.testclassification.SmallTests; +import org.junit.ClassRule; +import org.junit.Test; +import org.junit.experimental.categories.Category; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + + +/** +* Basic
[6/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/checkstyle.rss -- diff --git a/checkstyle.rss b/checkstyle.rss index eafb2c1..6ccf181 100644 --- a/checkstyle.rss +++ b/checkstyle.rss @@ -26,7 +26,7 @@ under the License. 2007 - 2018 The Apache Software Foundation File: 3753, - Errors: 15205, + Errors: 15206, Warnings: 0, Infos: 0 @@ -51883,7 +51883,7 @@ under the License. 0 - 20 + 21 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/coc.html -- diff --git a/coc.html b/coc.html index fbf11ff..6887cd9 100644 --- a/coc.html +++ b/coc.html @@ -7,7 +7,7 @@ - + Apache HBase Code of Conduct Policy @@ -375,7 +375,7 @@ email to mailto:priv...@hbase.apache.org;>the priv https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/dependencies.html -- diff --git a/dependencies.html b/dependencies.html index a830813..c7d8238 100644 --- a/dependencies.html +++ b/dependencies.html @@ -7,7 +7,7 @@ - + Apache HBase Project Dependencies @@ -440,7 +440,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/dependency-convergence.html -- diff --git a/dependency-convergence.html b/dependency-convergence.html index 5c46ebb..463a7cf 100644 --- a/dependency-convergence.html +++ b/dependency-convergence.html @@ -7,7 +7,7 @@ - + Apache HBase Reactor Dependency Convergence @@ -879,7 +879,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/dependency-info.html -- diff --git a/dependency-info.html b/dependency-info.html index ee66a24..2bbf59d 100644 --- a/dependency-info.html +++ b/dependency-info.html @@ -7,7 +7,7 @@ - + Apache HBase Dependency Information @@ -313,7 +313,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/dependency-management.html -- diff --git a/dependency-management.html b/dependency-management.html index 34cab1e..d53d5b4 100644 --- a/dependency-management.html +++ b/dependency-management.html @@ -7,7 +7,7 @@ - + Apache HBase Project Dependency Management @@ -1005,7 +1005,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/devapidocs/constant-values.html -- diff --git a/devapidocs/constant-values.html b/devapidocs/constant-values.html index 544fb19..463684c 100644 --- a/devapidocs/constant-values.html +++ b/devapidocs/constant-values.html @@ -3824,21 +3824,21 @@ publicstaticfinalhttps://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">String date -"Tue Oct 2 14:44:08 UTC 2018" +"Thu Oct 4 14:44:15 UTC 2018" publicstaticfinalhttps://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">String revision
[2/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForScanObserver.html -- diff --git a/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForScanObserver.html b/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForScanObserver.html index 0ab2840..07d3ab0 100644 --- a/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForScanObserver.html +++ b/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForScanObserver.html @@ -61,1084 +61,1085 @@ 053import org.apache.hadoop.hbase.coprocessor.RegionCoprocessor; 054import org.apache.hadoop.hbase.coprocessor.RegionCoprocessorEnvironment; 055import org.apache.hadoop.hbase.coprocessor.RegionObserver; -056import org.apache.hadoop.hbase.ipc.CoprocessorRpcUtils; -057import org.apache.hadoop.hbase.ipc.ServerRpcController; -058import org.apache.hadoop.hbase.protobuf.generated.MultiRowMutationProtos; -059import org.apache.hadoop.hbase.regionserver.HRegion; -060import org.apache.hadoop.hbase.regionserver.HRegionServer; -061import org.apache.hadoop.hbase.regionserver.MiniBatchOperationInProgress; -062import org.apache.hadoop.hbase.regionserver.RegionScanner; -063import org.apache.hadoop.hbase.testclassification.ClientTests; -064import org.apache.hadoop.hbase.testclassification.LargeTests; -065import org.apache.hadoop.hbase.util.Bytes; -066import org.apache.hadoop.hbase.util.Pair; -067import org.junit.After; -068import org.junit.AfterClass; -069import org.junit.Assert; -070import org.junit.Before; -071import org.junit.BeforeClass; -072import org.junit.ClassRule; -073import org.junit.Rule; -074import org.junit.Test; -075import org.junit.experimental.categories.Category; -076import org.junit.rules.TestName; -077import org.slf4j.Logger; -078import org.slf4j.LoggerFactory; -079 -080import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; -081import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos; -082 -083@Category({LargeTests.class, ClientTests.class}) -084public class TestFromClientSide3 { -085 -086 @ClassRule -087 public static final HBaseClassTestRule CLASS_RULE = -088 HBaseClassTestRule.forClass(TestFromClientSide3.class); -089 -090 private static final Logger LOG = LoggerFactory.getLogger(TestFromClientSide3.class); -091 private final static HBaseTestingUtility TEST_UTIL -092= new HBaseTestingUtility(); -093 private static byte[] FAMILY = Bytes.toBytes("testFamily"); -094 private static Random random = new Random(); -095 private static int SLAVES = 3; -096 private static final byte[] ROW = Bytes.toBytes("testRow"); -097 private static final byte[] ANOTHERROW = Bytes.toBytes("anotherrow"); -098 private static final byte[] QUALIFIER = Bytes.toBytes("testQualifier"); -099 private static final byte[] VALUE = Bytes.toBytes("testValue"); -100 private static final byte[] COL_QUAL = Bytes.toBytes("f1"); -101 private static final byte[] VAL_BYTES = Bytes.toBytes("v1"); -102 private static final byte[] ROW_BYTES = Bytes.toBytes("r1"); -103 -104 @Rule -105 public TestName name = new TestName(); -106 -107 /** -108 * @throws java.lang.Exception -109 */ -110 @BeforeClass -111 public static void setUpBeforeClass() throws Exception { -112TEST_UTIL.startMiniCluster(SLAVES); -113 } -114 -115 /** -116 * @throws java.lang.Exception -117 */ -118 @AfterClass -119 public static void tearDownAfterClass() throws Exception { -120TEST_UTIL.shutdownMiniCluster(); -121 } -122 -123 /** -124 * @throws java.lang.Exception -125 */ -126 @Before -127 public void setUp() throws Exception { -128// Nothing to do. -129 } -130 -131 /** -132 * @throws java.lang.Exception -133 */ -134 @After -135 public void tearDown() throws Exception { -136for (HTableDescriptor htd: TEST_UTIL.getAdmin().listTables()) { -137 LOG.info("Tear down, remove table=" + htd.getTableName()); -138 TEST_UTIL.deleteTable(htd.getTableName()); -139 } +056import org.apache.hadoop.hbase.exceptions.UnknownProtocolException; +057import org.apache.hadoop.hbase.ipc.CoprocessorRpcUtils; +058import org.apache.hadoop.hbase.ipc.ServerRpcController; +059import org.apache.hadoop.hbase.protobuf.generated.MultiRowMutationProtos; +060import org.apache.hadoop.hbase.regionserver.HRegion; +061import org.apache.hadoop.hbase.regionserver.HRegionServer; +062import org.apache.hadoop.hbase.regionserver.MiniBatchOperationInProgress; +063import org.apache.hadoop.hbase.regionserver.RegionScanner; +064import org.apache.hadoop.hbase.testclassification.ClientTests; +065import org.apache.hadoop.hbase.testclassification.LargeTests; +066import org.apache.hadoop.hbase.util.Bytes; +067import org.apache.hadoop.hbase.util.Pair; +068import
[8/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
Published site at 4508f670b136ae36325016e8d51b784ab0ec490b. Project: http://git-wip-us.apache.org/repos/asf/hbase-site/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase-site/commit/04fd4290 Tree: http://git-wip-us.apache.org/repos/asf/hbase-site/tree/04fd4290 Diff: http://git-wip-us.apache.org/repos/asf/hbase-site/diff/04fd4290 Branch: refs/heads/asf-site Commit: 04fd4290a6e5e182942c91437e3142c3dfd9805d Parents: 5b11381 Author: jenkins Authored: Thu Oct 4 14:52:32 2018 + Committer: jenkins Committed: Thu Oct 4 14:52:32 2018 + -- acid-semantics.html | 4 +- apache_hbase_reference_guide.pdf| 4 +- book.html | 2 +- bulk-loads.html | 4 +- checkstyle-aggregate.html | 27694 + checkstyle.rss | 4 +- coc.html| 4 +- dependencies.html | 4 +- dependency-convergence.html | 4 +- dependency-info.html| 4 +- dependency-management.html | 4 +- devapidocs/constant-values.html | 6 +- devapidocs/index-all.html | 6 + .../hadoop/hbase/backup/package-tree.html | 2 +- .../hadoop/hbase/client/package-tree.html |24 +- .../hadoop/hbase/coprocessor/package-tree.html | 2 +- .../hadoop/hbase/executor/package-tree.html | 2 +- .../hadoop/hbase/filter/package-tree.html | 8 +- .../hadoop/hbase/io/hfile/package-tree.html | 6 +- .../apache/hadoop/hbase/ipc/package-tree.html | 4 +- .../hadoop/hbase/mapreduce/package-tree.html| 4 +- .../hadoop/hbase/master/package-tree.html | 4 +- .../hbase/master/procedure/package-tree.html| 4 +- .../org/apache/hadoop/hbase/package-tree.html |20 +- .../hadoop/hbase/procedure2/package-tree.html | 4 +- .../hadoop/hbase/quotas/package-tree.html | 8 +- .../hadoop/hbase/regionserver/package-tree.html |18 +- .../regionserver/querymatcher/package-tree.html | 4 +- .../hbase/regionserver/wal/package-tree.html| 2 +- .../hadoop/hbase/replication/package-tree.html | 2 +- .../hbase/security/access/package-tree.html | 4 +- .../hadoop/hbase/security/package-tree.html | 2 +- .../hadoop/hbase/thrift/package-tree.html | 2 +- .../apache/hadoop/hbase/util/package-tree.html | 8 +- .../hadoop/hbase/wal/WALPrettyPrinter.html |77 +- .../org/apache/hadoop/hbase/Version.html| 6 +- .../hadoop/hbase/wal/WALPrettyPrinter.html | 705 +- downloads.html | 4 +- export_control.html | 4 +- index.html | 4 +- integration.html| 4 +- issue-tracking.html | 4 +- license.html| 4 +- mail-lists.html | 4 +- metrics.html| 4 +- old_news.html | 4 +- plugin-management.html | 4 +- plugins.html| 4 +- poweredbyhbase.html | 4 +- project-info.html | 4 +- project-reports.html| 4 +- project-summary.html| 4 +- pseudo-distributed.html | 4 +- replication.html| 4 +- resources.html | 4 +- source-repository.html | 4 +- sponsors.html | 4 +- supportingprojects.html | 4 +- team-list.html | 4 +- ...tSide3.WaitingForMultiMutationsObserver.html |10 +- ...tFromClientSide3.WaitingForScanObserver.html |12 +- .../hbase/client/TestFromClientSide3.html |98 +- ...tSide3.WaitingForMultiMutationsObserver.html | 2153 +- ...tFromClientSide3.WaitingForScanObserver.html | 2153 +- .../hbase/client/TestFromClientSide3.html | 2153 +- 65 files changed, 17702 insertions(+), 17631 deletions(-) -- http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/acid-semantics.html -- diff --git a/acid-semantics.html b/acid-semantics.html index 63433e5..017fb5c 100644 --- a/acid-semantics.html +++ b/acid-semantics.html @@ -7,7 +7,7 @@ -
[4/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/export_control.html -- diff --git a/export_control.html b/export_control.html index ee0fece..d183331 100644 --- a/export_control.html +++ b/export_control.html @@ -7,7 +7,7 @@ - + Apache HBase Export Control @@ -331,7 +331,7 @@ for more details. https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/index.html -- diff --git a/index.html b/index.html index 9fc5e76..620f5c1 100644 --- a/index.html +++ b/index.html @@ -7,7 +7,7 @@ - + Apache HBase Apache HBase⢠Home @@ -411,7 +411,7 @@ Apache HBase is an open-source, distributed, versioned, non-relational database https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/integration.html -- diff --git a/integration.html b/integration.html index a01c528..2838472 100644 --- a/integration.html +++ b/integration.html @@ -7,7 +7,7 @@ - + Apache HBase CI Management @@ -291,7 +291,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/issue-tracking.html -- diff --git a/issue-tracking.html b/issue-tracking.html index 5ad20ae..055d786 100644 --- a/issue-tracking.html +++ b/issue-tracking.html @@ -7,7 +7,7 @@ - + Apache HBase Issue Management @@ -288,7 +288,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/license.html -- diff --git a/license.html b/license.html index 17db7f0..ff8fbb9 100644 --- a/license.html +++ b/license.html @@ -7,7 +7,7 @@ - + Apache HBase Project Licenses @@ -491,7 +491,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/mail-lists.html -- diff --git a/mail-lists.html b/mail-lists.html index 9036efb..986c199 100644 --- a/mail-lists.html +++ b/mail-lists.html @@ -7,7 +7,7 @@ - + Apache HBase Project Mailing Lists @@ -341,7 +341,7 @@ https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/metrics.html -- diff --git a/metrics.html b/metrics.html index 1f21c24..c26076d 100644 --- a/metrics.html +++ b/metrics.html @@ -7,7 +7,7 @@ - + Apache HBase Apache HBase (TM) Metrics @@ -459,7 +459,7 @@ export HBASE_REGIONSERVER_OPTS=$HBASE_JMX_OPTS -Dcom.sun.management.jmxrem https://www.apache.org/;>The Apache Software Foundation. All rights reserved. - Last Published: 2018-10-02 + Last Published: 2018-10-04 http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/old_news.html -- diff --git a/old_news.html b/old_news.html index
[7/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/checkstyle-aggregate.html -- diff --git a/checkstyle-aggregate.html b/checkstyle-aggregate.html index d45fc93..99e656a 100644 --- a/checkstyle-aggregate.html +++ b/checkstyle-aggregate.html @@ -7,7 +7,7 @@ - + Apache HBase Checkstyle Results @@ -284,7 +284,7 @@ 3753 0 0 -15205 +15206 Files @@ -1842,7 +1842,7 @@ org/apache/hadoop/hbase/client/TestFromClientSide3.java 0 0 -20 +21 org/apache/hadoop/hbase/client/TestFromClientSideNoCodec.java 0 @@ -9849,7 +9849,7 @@ max: 100 ignorePattern: ^package.*|^import.*|a href|href|http://|https://|ftp://|org.apache.thrift.|com.google.protobuf.|hbase.protobuf.generated -1485 +1486 Error @@ -30818,137 +30818,143 @@ javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. -108 +109 Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. -116 +117 Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. -124 +125 Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. -132 +133 Error indentation Indentation 'for rcurly' has incorrect indentation level 2, expected level should be 4. -139 +140 Error indentation Indentation 'throws' has incorrect indentation level 2, expected level should be 4. -155 +156 Error coding InnerAssignment Inner assignments should be avoided. -329 +330 Error coding InnerAssignment Inner assignments should be avoided. -355 +356 Error coding InnerAssignment Inner assignments should be avoided. -390 +391 Error whitespace MethodParamPad '(' is preceded with whitespace. -401 +402 Error indentation Indentation 'method def' child has incorrect indentation level 6, expected level should be 4. -402 +403 Error indentation Indentation 'method def' child has incorrect indentation level 6, expected level should be 4. -493 +494 Error whitespace MethodParamPad '(' is preceded with whitespace. -610 +611 Error sizes LineLength Line is longer than 100 characters (found 105). -656 +657 Error sizes LineLength Line is longer than 100 characters (found 106). -786 +787 Error +sizes +LineLength +Line is longer than 100 characters (found 118). +855 + +Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. -897 - +898 + Error whitespace ParenPad '(' is followed by whitespace. -910 - +911 + Error whitespace ParenPad '(' is followed by whitespace. -913 - +914 + Error whitespace ParenPad '(' is followed by whitespace. -924 - +925 + Error sizes LineLength Line is longer than 100 characters (found 105). -993 +994 org/apache/hadoop/hbase/client/TestFromClientSideNoCodec.java - + Severity Category Rule Message Line - + Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. 58 - + Error javadoc NonEmptyAtclauseDescription @@ -30957,19 +30963,19 @@ org/apache/hadoop/hbase/client/TestFromClientSideScanExcpetion.java - + Severity Category Rule Message Line - + Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. 176 - + Error javadoc NonEmptyAtclauseDescription @@ -30978,25 +30984,25 @@ org/apache/hadoop/hbase/client/TestGet.java - + Severity Category Rule Message Line - + Error sizes LineLength Line is longer than 100 characters (found 104). 125 - + Error sizes LineLength Line is longer than 100 characters (found 105). 131 - + Error sizes LineLength @@ -31005,37 +31011,37 @@ org/apache/hadoop/hbase/client/TestHBaseAdminNoCluster.java - + Severity Category Rule Message Line - + Error indentation Indentation 'throws' has incorrect indentation level 2, expected level should be 4. 89 - + Error indentation Indentation 'org' has incorrect indentation level 2, expected level should be 4. 90 - + Error blocks NeedBraces 'if' construct must use '{}'s. 121 - + Error sizes MethodLength Method length is 156 lines (max allowed is 150). 125 - + Error blocks LeftCurly @@ -31044,37 +31050,37 @@ org/apache/hadoop/hbase/client/TestHTableMultiplexer.java - + Severity Category Rule Message Line - + Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. 61 - + Error javadoc NonEmptyAtclauseDescription At-clause should have a non-empty description. 69 - + Error blocks NeedBraces 'if' construct must use '{}'s. 121 - + Error blocks NeedBraces 'if' construct must use '{}'s. 141 - + Error blocks NeedBraces @@ -31083,19 +31089,19 @@ org/apache/hadoop/hbase/client/TestHTableMultiplexerFlushCache.java - + Severity Category Rule Message Line - + Error javadoc NonEmptyAtclauseDescription At-clause should have a
[5/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/devapidocs/org/apache/hadoop/hbase/wal/WALPrettyPrinter.html -- diff --git a/devapidocs/org/apache/hadoop/hbase/wal/WALPrettyPrinter.html b/devapidocs/org/apache/hadoop/hbase/wal/WALPrettyPrinter.html index eff8e9f..b67b142 100644 --- a/devapidocs/org/apache/hadoop/hbase/wal/WALPrettyPrinter.html +++ b/devapidocs/org/apache/hadoop/hbase/wal/WALPrettyPrinter.html @@ -18,7 +18,7 @@ catch(err) { } //--> -var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":9,"i7":10,"i8":9,"i9":10,"i10":10,"i11":10,"i12":9}; +var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":9,"i7":10,"i8":9,"i9":10,"i10":10,"i11":10,"i12":10,"i13":9}; var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; var altColor = "altColor"; var rowColor = "rowColor"; @@ -170,14 +170,18 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html persistentOutput +private long +position + + private https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">String region - + private https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">String row - + private long sequence @@ -283,23 +287,29 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html void +setPosition(longposition) +sets the position to start seeking the WAL file + + + +void setRegionFilter(https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">Stringregion) sets the region by which output will be filtered - + void setRowFilter(https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">Stringrow) sets the region by which output will be filtered - + void setSequenceFilter(longsequence) sets the region by which output will be filtered - + private static https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true; title="class or interface in java.util">Maphttps://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">String,https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true; title="class or interface in java.lang">Object toStringMap(Cellcell) @@ -409,12 +419,21 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html - + MAPPER private static finalcom.fasterxml.jackson.databind.ObjectMapper MAPPER + + + + + +position +privatelong position + + @@ -429,7 +448,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html WALPrettyPrinter -publicWALPrettyPrinter() +publicWALPrettyPrinter() Basic constructor that simply initializes values to reasonable defaults. @@ -439,7 +458,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html WALPrettyPrinter -publicWALPrettyPrinter(booleanoutputValues, +publicWALPrettyPrinter(booleanoutputValues, booleanoutputJSON, longsequence, https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">Stringregion, @@ -480,7 +499,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html enableValues -publicvoidenableValues() +publicvoidenableValues() turns value output on @@ -490,7 +509,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html disableValues -publicvoiddisableValues() +publicvoiddisableValues() turns value output off @@ -500,7 +519,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html enableJSON -publicvoidenableJSON() +publicvoidenableJSON() turns JSON output on @@ -510,7 +529,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html disableJSON -publicvoiddisableJSON() +publicvoiddisableJSON() turns JSON output off, and turns on "pretty strings" for human consumption @@ -520,7 +539,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html setSequenceFilter -publicvoidsetSequenceFilter(longsequence) +publicvoidsetSequenceFilter(longsequence) sets the region by which output will be filtered Parameters: @@ -535,7 +554,7 @@ extends https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html setRegionFilter -publicvoidsetRegionFilter(https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true; title="class or interface in java.lang">Stringregion) +publicvoidsetRegionFilter(https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true;
hbase-site git commit: INFRA-10751 Empty commit
Repository: hbase-site Updated Branches: refs/heads/asf-site 04fd4290a -> 679e78887 INFRA-10751 Empty commit Project: http://git-wip-us.apache.org/repos/asf/hbase-site/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase-site/commit/679e7888 Tree: http://git-wip-us.apache.org/repos/asf/hbase-site/tree/679e7888 Diff: http://git-wip-us.apache.org/repos/asf/hbase-site/diff/679e7888 Branch: refs/heads/asf-site Commit: 679e7888701f334947f1120135e89fc5672acdfc Parents: 04fd429 Author: jenkins Authored: Thu Oct 4 14:52:48 2018 + Committer: jenkins Committed: Thu Oct 4 14:52:48 2018 + -- --
[1/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
Repository: hbase-site Updated Branches: refs/heads/asf-site 5b11381f6 -> 04fd4290a http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.html -- diff --git a/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.html b/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.html index 0ab2840..07d3ab0 100644 --- a/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.html +++ b/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.html @@ -61,1084 +61,1085 @@ 053import org.apache.hadoop.hbase.coprocessor.RegionCoprocessor; 054import org.apache.hadoop.hbase.coprocessor.RegionCoprocessorEnvironment; 055import org.apache.hadoop.hbase.coprocessor.RegionObserver; -056import org.apache.hadoop.hbase.ipc.CoprocessorRpcUtils; -057import org.apache.hadoop.hbase.ipc.ServerRpcController; -058import org.apache.hadoop.hbase.protobuf.generated.MultiRowMutationProtos; -059import org.apache.hadoop.hbase.regionserver.HRegion; -060import org.apache.hadoop.hbase.regionserver.HRegionServer; -061import org.apache.hadoop.hbase.regionserver.MiniBatchOperationInProgress; -062import org.apache.hadoop.hbase.regionserver.RegionScanner; -063import org.apache.hadoop.hbase.testclassification.ClientTests; -064import org.apache.hadoop.hbase.testclassification.LargeTests; -065import org.apache.hadoop.hbase.util.Bytes; -066import org.apache.hadoop.hbase.util.Pair; -067import org.junit.After; -068import org.junit.AfterClass; -069import org.junit.Assert; -070import org.junit.Before; -071import org.junit.BeforeClass; -072import org.junit.ClassRule; -073import org.junit.Rule; -074import org.junit.Test; -075import org.junit.experimental.categories.Category; -076import org.junit.rules.TestName; -077import org.slf4j.Logger; -078import org.slf4j.LoggerFactory; -079 -080import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; -081import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos; -082 -083@Category({LargeTests.class, ClientTests.class}) -084public class TestFromClientSide3 { -085 -086 @ClassRule -087 public static final HBaseClassTestRule CLASS_RULE = -088 HBaseClassTestRule.forClass(TestFromClientSide3.class); -089 -090 private static final Logger LOG = LoggerFactory.getLogger(TestFromClientSide3.class); -091 private final static HBaseTestingUtility TEST_UTIL -092= new HBaseTestingUtility(); -093 private static byte[] FAMILY = Bytes.toBytes("testFamily"); -094 private static Random random = new Random(); -095 private static int SLAVES = 3; -096 private static final byte[] ROW = Bytes.toBytes("testRow"); -097 private static final byte[] ANOTHERROW = Bytes.toBytes("anotherrow"); -098 private static final byte[] QUALIFIER = Bytes.toBytes("testQualifier"); -099 private static final byte[] VALUE = Bytes.toBytes("testValue"); -100 private static final byte[] COL_QUAL = Bytes.toBytes("f1"); -101 private static final byte[] VAL_BYTES = Bytes.toBytes("v1"); -102 private static final byte[] ROW_BYTES = Bytes.toBytes("r1"); -103 -104 @Rule -105 public TestName name = new TestName(); -106 -107 /** -108 * @throws java.lang.Exception -109 */ -110 @BeforeClass -111 public static void setUpBeforeClass() throws Exception { -112TEST_UTIL.startMiniCluster(SLAVES); -113 } -114 -115 /** -116 * @throws java.lang.Exception -117 */ -118 @AfterClass -119 public static void tearDownAfterClass() throws Exception { -120TEST_UTIL.shutdownMiniCluster(); -121 } -122 -123 /** -124 * @throws java.lang.Exception -125 */ -126 @Before -127 public void setUp() throws Exception { -128// Nothing to do. -129 } -130 -131 /** -132 * @throws java.lang.Exception -133 */ -134 @After -135 public void tearDown() throws Exception { -136for (HTableDescriptor htd: TEST_UTIL.getAdmin().listTables()) { -137 LOG.info("Tear down, remove table=" + htd.getTableName()); -138 TEST_UTIL.deleteTable(htd.getTableName()); -139 } +056import org.apache.hadoop.hbase.exceptions.UnknownProtocolException; +057import org.apache.hadoop.hbase.ipc.CoprocessorRpcUtils; +058import org.apache.hadoop.hbase.ipc.ServerRpcController; +059import org.apache.hadoop.hbase.protobuf.generated.MultiRowMutationProtos; +060import org.apache.hadoop.hbase.regionserver.HRegion; +061import org.apache.hadoop.hbase.regionserver.HRegionServer; +062import org.apache.hadoop.hbase.regionserver.MiniBatchOperationInProgress; +063import org.apache.hadoop.hbase.regionserver.RegionScanner; +064import org.apache.hadoop.hbase.testclassification.ClientTests; +065import org.apache.hadoop.hbase.testclassification.LargeTests; +066import org.apache.hadoop.hbase.util.Bytes; +067import org.apache.hadoop.hbase.util.Pair; +068import org.junit.After; +069import
[3/8] hbase-site git commit: Published site at 4508f670b136ae36325016e8d51b784ab0ec490b.
http://git-wip-us.apache.org/repos/asf/hbase-site/blob/04fd4290/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForMultiMutationsObserver.html -- diff --git a/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForMultiMutationsObserver.html b/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForMultiMutationsObserver.html index 0ab2840..07d3ab0 100644 --- a/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForMultiMutationsObserver.html +++ b/testdevapidocs/src-html/org/apache/hadoop/hbase/client/TestFromClientSide3.WaitingForMultiMutationsObserver.html @@ -61,1084 +61,1085 @@ 053import org.apache.hadoop.hbase.coprocessor.RegionCoprocessor; 054import org.apache.hadoop.hbase.coprocessor.RegionCoprocessorEnvironment; 055import org.apache.hadoop.hbase.coprocessor.RegionObserver; -056import org.apache.hadoop.hbase.ipc.CoprocessorRpcUtils; -057import org.apache.hadoop.hbase.ipc.ServerRpcController; -058import org.apache.hadoop.hbase.protobuf.generated.MultiRowMutationProtos; -059import org.apache.hadoop.hbase.regionserver.HRegion; -060import org.apache.hadoop.hbase.regionserver.HRegionServer; -061import org.apache.hadoop.hbase.regionserver.MiniBatchOperationInProgress; -062import org.apache.hadoop.hbase.regionserver.RegionScanner; -063import org.apache.hadoop.hbase.testclassification.ClientTests; -064import org.apache.hadoop.hbase.testclassification.LargeTests; -065import org.apache.hadoop.hbase.util.Bytes; -066import org.apache.hadoop.hbase.util.Pair; -067import org.junit.After; -068import org.junit.AfterClass; -069import org.junit.Assert; -070import org.junit.Before; -071import org.junit.BeforeClass; -072import org.junit.ClassRule; -073import org.junit.Rule; -074import org.junit.Test; -075import org.junit.experimental.categories.Category; -076import org.junit.rules.TestName; -077import org.slf4j.Logger; -078import org.slf4j.LoggerFactory; -079 -080import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; -081import org.apache.hadoop.hbase.shaded.protobuf.generated.AdminProtos; -082 -083@Category({LargeTests.class, ClientTests.class}) -084public class TestFromClientSide3 { -085 -086 @ClassRule -087 public static final HBaseClassTestRule CLASS_RULE = -088 HBaseClassTestRule.forClass(TestFromClientSide3.class); -089 -090 private static final Logger LOG = LoggerFactory.getLogger(TestFromClientSide3.class); -091 private final static HBaseTestingUtility TEST_UTIL -092= new HBaseTestingUtility(); -093 private static byte[] FAMILY = Bytes.toBytes("testFamily"); -094 private static Random random = new Random(); -095 private static int SLAVES = 3; -096 private static final byte[] ROW = Bytes.toBytes("testRow"); -097 private static final byte[] ANOTHERROW = Bytes.toBytes("anotherrow"); -098 private static final byte[] QUALIFIER = Bytes.toBytes("testQualifier"); -099 private static final byte[] VALUE = Bytes.toBytes("testValue"); -100 private static final byte[] COL_QUAL = Bytes.toBytes("f1"); -101 private static final byte[] VAL_BYTES = Bytes.toBytes("v1"); -102 private static final byte[] ROW_BYTES = Bytes.toBytes("r1"); -103 -104 @Rule -105 public TestName name = new TestName(); -106 -107 /** -108 * @throws java.lang.Exception -109 */ -110 @BeforeClass -111 public static void setUpBeforeClass() throws Exception { -112TEST_UTIL.startMiniCluster(SLAVES); -113 } -114 -115 /** -116 * @throws java.lang.Exception -117 */ -118 @AfterClass -119 public static void tearDownAfterClass() throws Exception { -120TEST_UTIL.shutdownMiniCluster(); -121 } -122 -123 /** -124 * @throws java.lang.Exception -125 */ -126 @Before -127 public void setUp() throws Exception { -128// Nothing to do. -129 } -130 -131 /** -132 * @throws java.lang.Exception -133 */ -134 @After -135 public void tearDown() throws Exception { -136for (HTableDescriptor htd: TEST_UTIL.getAdmin().listTables()) { -137 LOG.info("Tear down, remove table=" + htd.getTableName()); -138 TEST_UTIL.deleteTable(htd.getTableName()); -139 } +056import org.apache.hadoop.hbase.exceptions.UnknownProtocolException; +057import org.apache.hadoop.hbase.ipc.CoprocessorRpcUtils; +058import org.apache.hadoop.hbase.ipc.ServerRpcController; +059import org.apache.hadoop.hbase.protobuf.generated.MultiRowMutationProtos; +060import org.apache.hadoop.hbase.regionserver.HRegion; +061import org.apache.hadoop.hbase.regionserver.HRegionServer; +062import org.apache.hadoop.hbase.regionserver.MiniBatchOperationInProgress; +063import org.apache.hadoop.hbase.regionserver.RegionScanner; +064import org.apache.hadoop.hbase.testclassification.ClientTests; +065import org.apache.hadoop.hbase.testclassification.LargeTests; +066import org.apache.hadoop.hbase.util.Bytes; +067import
hbase git commit: HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes
Repository: hbase Updated Branches: refs/heads/master b9bb14e0f -> 4508f670b HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes Signed-off-by: Allan Yang Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/4508f670 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/4508f670 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/4508f670 Branch: refs/heads/master Commit: 4508f670b136ae36325016e8d51b784ab0ec490b Parents: b9bb14e Author: Wellington Chevreuil Authored: Tue Oct 2 15:55:52 2018 +0100 Committer: Michael Stack Committed: Thu Oct 4 03:32:18 2018 -0700 -- .../hadoop/hbase/wal/WALPrettyPrinter.java | 23 1 file changed, 23 insertions(+) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/4508f670/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java -- diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java index 3fa496f..281f3c9 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java @@ -84,6 +84,8 @@ public class WALPrettyPrinter { private PrintStream out; // for JSON encoding private static final ObjectMapper MAPPER = new ObjectMapper(); + //allows for jumping straight to a given portion of the file + private long position; /** * Basic constructor that simply initializes values to reasonable defaults. @@ -202,6 +204,15 @@ public class WALPrettyPrinter { } /** + * sets the position to start seeking the WAL file + * @param position + * initial position to start seeking the given WAL file + */ + public void setPosition(long position) { +this.position = position; + } + + /** * enables output as a single, persistent list. at present, only relevant in * the case of JSON output. */ @@ -274,6 +285,10 @@ public class WALPrettyPrinter { firstTxn = true; } +if (position > 0) { + log.seek(position); +} + try { WAL.Entry entry; while ((entry = log.next()) != null) { @@ -297,6 +312,7 @@ public class WALPrettyPrinter { if (row == null || ((String) op.get("row")).equals(row)) { actions.add(op); } + op.put("total_size_sum", PrivateCellUtil.estimatedSizeOfCell(cell)); } if (actions.isEmpty()) continue; @@ -321,8 +337,11 @@ public class WALPrettyPrinter { out.println("tag: " + op.get("tag")); } if (outputValues) out.println("value: " + op.get("value")); +out.println("cell total size sum: " + op.get("total_size_sum")); } } +out.println("edit heap size: " + entry.getEdit().heapSize()); +out.println("position: " + log.getPosition()); } } finally { log.close(); @@ -380,6 +399,7 @@ public class WALPrettyPrinter { options.addOption("s", "sequence", true, "Sequence to filter by. Pass sequence number."); options.addOption("w", "row", true, "Row to filter by. Pass row name."); +options.addOption("g", "goto", true, "Position to seek to in the file"); WALPrettyPrinter printer = new WALPrettyPrinter(); CommandLineParser parser = new PosixParser(); @@ -403,6 +423,9 @@ public class WALPrettyPrinter { printer.setSequenceFilter(Long.parseLong(cmd.getOptionValue("s"))); if (cmd.hasOption("w")) printer.setRowFilter(cmd.getOptionValue("w")); + if (cmd.hasOption("g")) { +printer.setPosition(Long.parseLong(cmd.getOptionValue("g"))); + } } catch (ParseException e) { LOG.error("Failed to parse commandLine arguments", e); HelpFormatter formatter = new HelpFormatter();
hbase git commit: HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes
Repository: hbase Updated Branches: refs/heads/branch-2 8a5537b5f -> 9e3f3fdc1 HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes Signed-off-by: Allan Yang Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/9e3f3fdc Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/9e3f3fdc Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/9e3f3fdc Branch: refs/heads/branch-2 Commit: 9e3f3fdc1f2c95957a735cf5a83ab06ea76f80b8 Parents: 8a5537b Author: Wellington Chevreuil Authored: Tue Oct 2 15:55:52 2018 +0100 Committer: Michael Stack Committed: Thu Oct 4 03:31:15 2018 -0700 -- .../hadoop/hbase/wal/WALPrettyPrinter.java | 23 1 file changed, 23 insertions(+) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/9e3f3fdc/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java -- diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java index 85877fe..45934d4 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java @@ -80,6 +80,8 @@ public class WALPrettyPrinter { private PrintStream out; // for JSON encoding private static final ObjectMapper MAPPER = new ObjectMapper(); + //allows for jumping straight to a given portion of the file + private long position; /** * Basic constructor that simply initializes values to reasonable defaults. @@ -198,6 +200,15 @@ public class WALPrettyPrinter { } /** + * sets the position to start seeking the WAL file + * @param position + * initial position to start seeking the given WAL file + */ + public void setPosition(long position) { +this.position = position; + } + + /** * enables output as a single, persistent list. at present, only relevant in * the case of JSON output. */ @@ -270,6 +281,10 @@ public class WALPrettyPrinter { firstTxn = true; } +if (position > 0) { + log.seek(position); +} + try { WAL.Entry entry; while ((entry = log.next()) != null) { @@ -293,6 +308,7 @@ public class WALPrettyPrinter { if (row == null || ((String) op.get("row")).equals(row)) { actions.add(op); } + op.put("total_size_sum", PrivateCellUtil.estimatedSizeOfCell(cell)); } if (actions.isEmpty()) continue; @@ -317,8 +333,11 @@ public class WALPrettyPrinter { out.println("tag: " + op.get("tag")); } if (outputValues) out.println("value: " + op.get("value")); +out.println("cell total size sum: " + op.get("total_size_sum")); } } +out.println("edit heap size: " + entry.getEdit().heapSize()); +out.println("position: " + log.getPosition()); } } finally { log.close(); @@ -376,6 +395,7 @@ public class WALPrettyPrinter { options.addOption("s", "sequence", true, "Sequence to filter by. Pass sequence number."); options.addOption("w", "row", true, "Row to filter by. Pass row name."); +options.addOption("g", "goto", true, "Position to seek to in the file"); WALPrettyPrinter printer = new WALPrettyPrinter(); CommandLineParser parser = new PosixParser(); @@ -399,6 +419,9 @@ public class WALPrettyPrinter { printer.setSequenceFilter(Long.parseLong(cmd.getOptionValue("s"))); if (cmd.hasOption("w")) printer.setRowFilter(cmd.getOptionValue("w")); + if (cmd.hasOption("g")) { +printer.setPosition(Long.parseLong(cmd.getOptionValue("g"))); + } } catch (ParseException e) { e.printStackTrace(); HelpFormatter formatter = new HelpFormatter();
hbase git commit: HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes
Repository: hbase Updated Branches: refs/heads/branch-2.1 3df8b6f7b -> b0ac1c6ab HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes Signed-off-by: Allan Yang Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/b0ac1c6a Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/b0ac1c6a Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/b0ac1c6a Branch: refs/heads/branch-2.1 Commit: b0ac1c6abaaad94b0e6eea6f37f4aabf4b4e8064 Parents: 3df8b6f Author: Wellington Chevreuil Authored: Tue Oct 2 15:55:52 2018 +0100 Committer: Michael Stack Committed: Thu Oct 4 03:28:21 2018 -0700 -- .../hadoop/hbase/wal/WALPrettyPrinter.java | 23 1 file changed, 23 insertions(+) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/b0ac1c6a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java -- diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java index 85877fe..45934d4 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java @@ -80,6 +80,8 @@ public class WALPrettyPrinter { private PrintStream out; // for JSON encoding private static final ObjectMapper MAPPER = new ObjectMapper(); + //allows for jumping straight to a given portion of the file + private long position; /** * Basic constructor that simply initializes values to reasonable defaults. @@ -198,6 +200,15 @@ public class WALPrettyPrinter { } /** + * sets the position to start seeking the WAL file + * @param position + * initial position to start seeking the given WAL file + */ + public void setPosition(long position) { +this.position = position; + } + + /** * enables output as a single, persistent list. at present, only relevant in * the case of JSON output. */ @@ -270,6 +281,10 @@ public class WALPrettyPrinter { firstTxn = true; } +if (position > 0) { + log.seek(position); +} + try { WAL.Entry entry; while ((entry = log.next()) != null) { @@ -293,6 +308,7 @@ public class WALPrettyPrinter { if (row == null || ((String) op.get("row")).equals(row)) { actions.add(op); } + op.put("total_size_sum", PrivateCellUtil.estimatedSizeOfCell(cell)); } if (actions.isEmpty()) continue; @@ -317,8 +333,11 @@ public class WALPrettyPrinter { out.println("tag: " + op.get("tag")); } if (outputValues) out.println("value: " + op.get("value")); +out.println("cell total size sum: " + op.get("total_size_sum")); } } +out.println("edit heap size: " + entry.getEdit().heapSize()); +out.println("position: " + log.getPosition()); } } finally { log.close(); @@ -376,6 +395,7 @@ public class WALPrettyPrinter { options.addOption("s", "sequence", true, "Sequence to filter by. Pass sequence number."); options.addOption("w", "row", true, "Row to filter by. Pass row name."); +options.addOption("g", "goto", true, "Position to seek to in the file"); WALPrettyPrinter printer = new WALPrettyPrinter(); CommandLineParser parser = new PosixParser(); @@ -399,6 +419,9 @@ public class WALPrettyPrinter { printer.setSequenceFilter(Long.parseLong(cmd.getOptionValue("s"))); if (cmd.hasOption("w")) printer.setRowFilter(cmd.getOptionValue("w")); + if (cmd.hasOption("g")) { +printer.setPosition(Long.parseLong(cmd.getOptionValue("g"))); + } } catch (ParseException e) { e.printStackTrace(); HelpFormatter formatter = new HelpFormatter();
hbase git commit: HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes
Repository: hbase Updated Branches: refs/heads/branch-2.0 bc12f38b4 -> 7b7888e1c HBASE-21185 - WALPrettyPrinter: Additional useful info to be printed by wal printer tool, for debugability purposes Signed-off-by: Allan Yang Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/7b7888e1 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/7b7888e1 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/7b7888e1 Branch: refs/heads/branch-2.0 Commit: 7b7888e1cf123e867322b73f7c0e6e89ae900e1c Parents: bc12f38 Author: Wellington Chevreuil Authored: Tue Oct 2 15:55:52 2018 +0100 Committer: Michael Stack Committed: Thu Oct 4 03:19:38 2018 -0700 -- .../hadoop/hbase/wal/WALPrettyPrinter.java | 23 1 file changed, 23 insertions(+) -- http://git-wip-us.apache.org/repos/asf/hbase/blob/7b7888e1/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java -- diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java index 85877fe..45934d4 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALPrettyPrinter.java @@ -80,6 +80,8 @@ public class WALPrettyPrinter { private PrintStream out; // for JSON encoding private static final ObjectMapper MAPPER = new ObjectMapper(); + //allows for jumping straight to a given portion of the file + private long position; /** * Basic constructor that simply initializes values to reasonable defaults. @@ -198,6 +200,15 @@ public class WALPrettyPrinter { } /** + * sets the position to start seeking the WAL file + * @param position + * initial position to start seeking the given WAL file + */ + public void setPosition(long position) { +this.position = position; + } + + /** * enables output as a single, persistent list. at present, only relevant in * the case of JSON output. */ @@ -270,6 +281,10 @@ public class WALPrettyPrinter { firstTxn = true; } +if (position > 0) { + log.seek(position); +} + try { WAL.Entry entry; while ((entry = log.next()) != null) { @@ -293,6 +308,7 @@ public class WALPrettyPrinter { if (row == null || ((String) op.get("row")).equals(row)) { actions.add(op); } + op.put("total_size_sum", PrivateCellUtil.estimatedSizeOfCell(cell)); } if (actions.isEmpty()) continue; @@ -317,8 +333,11 @@ public class WALPrettyPrinter { out.println("tag: " + op.get("tag")); } if (outputValues) out.println("value: " + op.get("value")); +out.println("cell total size sum: " + op.get("total_size_sum")); } } +out.println("edit heap size: " + entry.getEdit().heapSize()); +out.println("position: " + log.getPosition()); } } finally { log.close(); @@ -376,6 +395,7 @@ public class WALPrettyPrinter { options.addOption("s", "sequence", true, "Sequence to filter by. Pass sequence number."); options.addOption("w", "row", true, "Row to filter by. Pass row name."); +options.addOption("g", "goto", true, "Position to seek to in the file"); WALPrettyPrinter printer = new WALPrettyPrinter(); CommandLineParser parser = new PosixParser(); @@ -399,6 +419,9 @@ public class WALPrettyPrinter { printer.setSequenceFilter(Long.parseLong(cmd.getOptionValue("s"))); if (cmd.hasOption("w")) printer.setRowFilter(cmd.getOptionValue("w")); + if (cmd.hasOption("g")) { +printer.setPosition(Long.parseLong(cmd.getOptionValue("g"))); + } } catch (ParseException e) { e.printStackTrace(); HelpFormatter formatter = new HelpFormatter();