hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From apurt...@apache.org
Subject hbase git commit: HBASE-17587 Do not Rethrow DoNotRetryIOException as UnknownScannerException
Date Fri, 03 Feb 2017 01:12:26 GMT
Repository: hbase
Updated Branches:
  refs/heads/master 7294931e6 -> 537580bc5


HBASE-17587 Do not Rethrow DoNotRetryIOException as UnknownScannerException

Signed-off-by: Andrew Purtell <apurtell@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/537580bc
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/537580bc
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/537580bc

Branch: refs/heads/master
Commit: 537580bc51b4946c2cd2a5ac7b91fdbe9e2ec18d
Parents: 7294931
Author: Zach York <zyork@amazon.com>
Authored: Thu Feb 2 02:44:58 2017 -0800
Committer: Andrew Purtell <apurtell@apache.org>
Committed: Thu Feb 2 17:12:18 2017 -0800

----------------------------------------------------------------------
 .../apache/hadoop/hbase/regionserver/RSRpcServices.java   | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/537580bc/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
index e615246..925128c 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/RSRpcServices.java
@@ -83,7 +83,6 @@ import org.apache.hadoop.hbase.exceptions.OutOfOrderScannerNextException;
 import org.apache.hadoop.hbase.exceptions.ScannerResetException;
 import org.apache.hadoop.hbase.filter.ByteArrayComparable;
 import org.apache.hadoop.hbase.filter.CompareFilter.CompareOp;
-import org.apache.hadoop.hbase.io.hfile.CorruptHFileException;
 import org.apache.hadoop.hbase.ipc.HBaseRPCErrorHandler;
 import org.apache.hadoop.hbase.ipc.HBaseRpcController;
 import org.apache.hadoop.hbase.ipc.PriorityFunction;
@@ -3095,12 +3094,17 @@ public class RSRpcServices implements HBaseRPCErrorHandler,
         // row that the client has last seen.
         closeScanner(region, scanner, scannerName, context);
 
+        // rethrow DoNotRetryIOException. This can avoid the retry in ClientScanner.
+        if (e instanceof DoNotRetryIOException) {
+          throw e;
+        }
 
-        // If it is a CorruptHFileException or a FileNotFoundException, throw the
+        // If it is a FileNotFoundException, wrap as a
         // DoNotRetryIOException. This can avoid the retry in ClientScanner.
-        if (e instanceof CorruptHFileException || e instanceof FileNotFoundException) {
+        if (e instanceof FileNotFoundException) {
           throw new DoNotRetryIOException(e);
         }
+
         // We closed the scanner already. Instead of throwing the IOException, and client
         // retrying with the same scannerId only to get USE on the next RPC, we directly
throw
         // a special exception to save an RPC.


Mime
View raw message