Repository: hbase Updated Branches: refs/heads/master 25f7e804c -> a63e3ac83
HBASE-14041 Do not clear MetaCache if a ThrottlingException is thrown Signed-off-by: Sean Busbey <[email protected]> Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/a63e3ac8 Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/a63e3ac8 Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/a63e3ac8 Branch: refs/heads/master Commit: a63e3ac83ffb91948f464e4f62111d29adc02812 Parents: 25f7e80 Author: terence.yoo <[email protected]> Authored: Thu Jul 9 13:43:37 2015 +0900 Committer: Sean Busbey <[email protected]> Committed: Wed Jul 15 02:53:21 2015 -0500 ---------------------------------------------------------------------- .../hadoop/hbase/client/ConnectionImplementation.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hbase/blob/a63e3ac8/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ConnectionImplementation.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ConnectionImplementation.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ConnectionImplementation.java index 35ff34f..2754997 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ConnectionImplementation.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/ConnectionImplementation.java @@ -56,6 +56,7 @@ import org.apache.hadoop.hbase.protobuf.generated.ClientProtos; import org.apache.hadoop.hbase.protobuf.generated.MasterProtos; import org.apache.hadoop.hbase.protobuf.generated.MasterProtos.IsBalancerEnabledRequest; import org.apache.hadoop.hbase.protobuf.generated.MasterProtos.IsBalancerEnabledResponse; +import org.apache.hadoop.hbase.quotas.ThrottlingException; import org.apache.hadoop.hbase.regionserver.RegionServerStoppedException; import org.apache.hadoop.hbase.security.User; import org.apache.hadoop.hbase.util.Bytes; @@ -263,7 +264,8 @@ class ConnectionImplementation implements ClusterConnection, Closeable { * - hadoop.ipc wrapped exceptions * - nested exceptions * - * Looks for: RegionMovedException / RegionOpeningException / RegionTooBusyException + * Looks for: RegionMovedException / RegionOpeningException / RegionTooBusyException / + * ThrottlingException * @return null if we didn't find the exception, the exception otherwise. */ public static Throwable findException(Object exception) { @@ -273,7 +275,7 @@ class ConnectionImplementation implements ClusterConnection, Closeable { Throwable cur = (Throwable) exception; while (cur != null) { if (cur instanceof RegionMovedException || cur instanceof RegionOpeningException - || cur instanceof RegionTooBusyException) { + || cur instanceof RegionTooBusyException || cur instanceof ThrottlingException) { return cur; } if (cur instanceof RemoteException) { @@ -1840,7 +1842,8 @@ class ConnectionImplementation implements ClusterConnection, Closeable { HRegionInfo regionInfo = oldLocation.getRegionInfo(); Throwable cause = findException(exception); if (cause != null) { - if (cause instanceof RegionTooBusyException || cause instanceof RegionOpeningException) { + if (cause instanceof RegionTooBusyException || cause instanceof RegionOpeningException + || cause instanceof ThrottlingException) { // We know that the region is still on this region server return; }
