Return-Path: X-Original-To: apmail-hbase-commits-archive@www.apache.org Delivered-To: apmail-hbase-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6E78A10ECE for ; Wed, 17 Dec 2014 06:17:27 +0000 (UTC) Received: (qmail 16203 invoked by uid 500); 17 Dec 2014 06:17:27 -0000 Delivered-To: apmail-hbase-commits-archive@hbase.apache.org Received: (qmail 16158 invoked by uid 500); 17 Dec 2014 06:17:27 -0000 Mailing-List: contact commits-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hbase.apache.org Delivered-To: mailing list commits@hbase.apache.org Received: (qmail 16140 invoked by uid 99); 17 Dec 2014 06:17:27 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Dec 2014 06:17:27 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id DB15CA2EC02; Wed, 17 Dec 2014 06:17:26 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: apurtell@apache.org To: commits@hbase.apache.org Date: Wed, 17 Dec 2014 06:17:26 -0000 Message-Id: <5718d3a28800473fb01a7554c5e23608@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [1/2] hbase git commit: Revert "HBASE-5162 Basic client pushback mechanism (Jesse Yates); ADDENDUM" Repository: hbase Updated Branches: refs/heads/master f7154e1ac -> 99a11390b Revert "HBASE-5162 Basic client pushback mechanism (Jesse Yates); ADDENDUM" This reverts commit f7154e1ac9e6c0bd2dd3c39078a52d49d3485504. Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/6a042c38 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/6a042c38 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/6a042c38 Branch: refs/heads/master Commit: 6a042c381a04ccd4b82bc51720af7a043e144445 Parents: f7154e1 Author: Andrew Purtell Authored: Tue Dec 16 22:14:50 2014 -0800 Committer: Andrew Purtell Committed: Tue Dec 16 22:14:50 2014 -0800 ---------------------------------------------------------------------- hbase-client/pom.xml | 44 ++++---------------- .../hbase/client/RpcRetryingCallerFactory.java | 9 ++-- .../client/StatsTrackingRpcRetryingCaller.java | 2 +- .../hadoop/hbase/client/TestClientPushback.java | 12 +++--- 4 files changed, 18 insertions(+), 49 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hbase/blob/6a042c38/hbase-client/pom.xml ---------------------------------------------------------------------- diff --git a/hbase-client/pom.xml b/hbase-client/pom.xml index a1d9cef..5d21ea3 100644 --- a/hbase-client/pom.xml +++ b/hbase-client/pom.xml @@ -108,16 +108,6 @@ org.apache.hbase hbase-common - - - org.apache.hadoop - hadoop-mapreduce-client-core - - - com.google.guava - guava - - org.apache.hbase @@ -146,6 +136,14 @@ commons-logging + com.google.guava + guava + + + com.google.protobuf + protobuf-java + + io.netty netty-all @@ -222,38 +220,14 @@ hadoop-common - com.google.code.findbugs - jsr305 - - - com.github.stephenc.findbugs - findbugs-annotations - - - net.java.dev.jets3t - jets3t - - javax.servlet.jsp jsp-api - org.mortbay.jetty - jetty - - com.sun.jersey jersey-server - com.sun.jersey - jersey-core - - - com.sun.jersey - jersey-json - - javax.servlet servlet-api @@ -267,7 +241,6 @@ - http://git-wip-us.apache.org/repos/asf/hbase/blob/6a042c38/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RpcRetryingCallerFactory.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RpcRetryingCallerFactory.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RpcRetryingCallerFactory.java index 0af8210..6f2760f 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RpcRetryingCallerFactory.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/RpcRetryingCallerFactory.java @@ -90,14 +90,11 @@ public class RpcRetryingCallerFactory { String clazzName = RpcRetryingCallerFactory.class.getName(); String rpcCallerFactoryClazz = configuration.get(RpcRetryingCallerFactory.CUSTOM_CALLER_CONF_KEY, clazzName); - RpcRetryingCallerFactory factory; if (rpcCallerFactoryClazz.equals(clazzName)) { - factory = new RpcRetryingCallerFactory(configuration, interceptor); - } else { - factory = ReflectionUtils.instantiateWithCustomCtor( - rpcCallerFactoryClazz, new Class[] { Configuration.class }, - new Object[] { configuration }); + return new RpcRetryingCallerFactory(configuration, interceptor); } + RpcRetryingCallerFactory factory = ReflectionUtils.instantiateWithCustomCtor( + rpcCallerFactoryClazz, new Class[] { Configuration.class }, new Object[] { configuration }); // setting for backwards compat with existing caller factories, rather than in the ctor factory.setStatisticTracker(stats); http://git-wip-us.apache.org/repos/asf/hbase/blob/6a042c38/hbase-client/src/main/java/org/apache/hadoop/hbase/client/StatsTrackingRpcRetryingCaller.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/StatsTrackingRpcRetryingCaller.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/StatsTrackingRpcRetryingCaller.java index e82f1e8..cec0ee5 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/StatsTrackingRpcRetryingCaller.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/StatsTrackingRpcRetryingCaller.java @@ -64,7 +64,7 @@ public class StatsTrackingRpcRetryingCaller implements RpcRetryingCaller { // mutli-server callables span multiple regions, so they don't have a location, // but they are region server callables, so we have to handle them when we process the - // result in AsyncProcess#receiveMultiAction, not in here + // result, not in here if (callable instanceof MultiServerCallable) { return result; } http://git-wip-us.apache.org/repos/asf/hbase/blob/6a042c38/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientPushback.java ---------------------------------------------------------------------- diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientPushback.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientPushback.java index 76914e0..dfb9a70 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientPushback.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientPushback.java @@ -50,7 +50,8 @@ public class TestClientPushback { conf.setBoolean(HConstants.ENABLE_CLIENT_BACKPRESSURE, true); // turn the memstore size way down so we don't need to write a lot to see changes in memstore // load - conf.setLong(HConstants.HREGION_MEMSTORE_FLUSH_SIZE, flushSizeBytes); + conf.setLong(HConstants.HREGION_MEMSTORE_FLUSH_SIZE, + flushSizeBytes); // ensure we block the flushes when we are double that flushsize conf.setLong("hbase.hregion.memstore.block.multiplier", 2); @@ -64,11 +65,10 @@ public class TestClientPushback { } @Test - public void testClientTracksServerPushback() throws Exception{ + public void testClientTrackesServerPushback() throws Exception{ Configuration conf = UTIL.getConfiguration(); TableName tablename = TableName.valueOf(tableName); - Connection conn = ConnectionFactory.createConnection(conf); - HTable table = (HTable) conn.getTable(tablename); + HTable table = new HTable(conf, tablename); //make sure we flush after each put table.setAutoFlushTo(true); @@ -78,8 +78,8 @@ public class TestClientPushback { table.put(p); // get the stats for the region hosting our table - ClusterConnection connection = table.connection; - ServerStatisticTracker stats = connection.getStatisticsTracker(); + ClusterConnection conn = ConnectionManager.getConnectionInternal(conf); + ServerStatisticTracker stats = conn.getStatisticsTracker(); assertNotNull( "No stats configured for the client!", stats); // get the names so we can query the stats ServerName server = UTIL.getHBaseCluster().getRegionServer(0).getServerName();