johnhomsea commented on a change in pull request #501: HBASE-22699 refactor 
isMetaClearingException
URL: https://github.com/apache/hbase/pull/501#discussion_r314986287
 
 

 ##########
 File path: 
hbase-client/src/main/java/org/apache/hadoop/hbase/exceptions/ClientExceptionsUtil.java
 ##########
 @@ -59,18 +58,22 @@ public static boolean isMetaClearingException(Throwable 
cur) {
     if (cur == null) {
       return true;
     }
-    return !isSpecialException(cur) || (cur instanceof RegionMovedException)
-        || cur instanceof NotServingRegionException;
+    return !regionDefinitelyOnTheRegionServerException(cur);
   }
 
-  public static boolean isSpecialException(Throwable cur) {
-    return (cur instanceof RegionMovedException || cur instanceof 
RegionOpeningException
-        || cur instanceof RegionTooBusyException || cur instanceof 
RpcThrottlingException
-        || cur instanceof MultiActionResultTooLarge || cur instanceof 
RetryImmediatelyException
-        || cur instanceof CallQueueTooBigException || cur instanceof 
CallDroppedException
-        || cur instanceof NotServingRegionException || cur instanceof 
RequestTooBigException);
+  private static boolean regionDefinitelyOnTheRegionServerException(Throwable 
t) {
+    return (t instanceof RegionTooBusyException || t instanceof 
RpcThrottlingException
+        || t instanceof RetryImmediatelyException || t instanceof 
CallQueueTooBigException
+        || t instanceof CallDroppedException || t instanceof 
RequestTooBigException);
 
 Review comment:
   Yes, the name is confusing and should be renamed.
   Yes, it is really a problem that the client has no change to update the meta 
in that situation. The problem here is this function is just return a boolean 
which says Yes or No. It seems we should add more status to carry this 
information, like Integer or something?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to