openinx commented on a change in pull request #163: HBASE-21995 Add a
coprocessor to set HDFS ACL for hbase granted user
URL: https://github.com/apache/hbase/pull/163#discussion_r293230650
##########
File path: hbase-server/src/main/java/org/apache/hadoop/hbase/io/FileLink.java
##########
@@ -312,14 +314,31 @@ private FSDataInputStream tryOpen() throws IOException {
}
currentPath = path;
return(in);
- } catch (FileNotFoundException e) {
- // Try another file location
- } catch (RemoteException re) {
- IOException ioe =
re.unwrapRemoteException(FileNotFoundException.class);
- if (!(ioe instanceof FileNotFoundException)) throw re;
+ } catch (FileNotFoundException | AccessControlException |
RemoteException e) {
+ exception = handleTryOpenException(e, exception);
+ }
+ }
+ throw exception;
+ }
+
+ private IOException handleTryOpenException(IOException newException,
Review comment:
Why need to save the previousException ? Can just check the given exception
e, and if e or its cause is FileNotFoundException or AccessControlException,
then return, else just throw ?
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services