[ https://issues.apache.org/jira/browse/HADOOP-14333?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15977642#comment-15977642 ]
Yongjun Zhang commented on HADOOP-14333: ---------------------------------------- Thanks [~aw] and [~shahrs87]. Agree that Hive project should have raised the issue before using it. {quote} unblock from what, exactly? {quote} The hive code that is broken is listed in the description. I was trying to propose that, as a temporary solution, we can let isHDFSEncryptionEnabled not to throw. Then we can coordinate a change between hadoop and hive to fix together. Thanks Rushabh for the sample code. I think in the case of SocketTimeOut, we should do some retry. If it's other exception, we return false. Let me post a patch to see if it makes sense. Thanks, > New exception thrown by (private) DFSClient API isHDFSEncryptionEnabled broke > hacky hive code > ---------------------------------------------------------------------------------------------- > > Key: HADOOP-14333 > URL: https://issues.apache.org/jira/browse/HADOOP-14333 > Project: Hadoop Common > Issue Type: Bug > Affects Versions: 2.8.1, 3.0.0-alpha3 > Reporter: Yongjun Zhang > Assignee: Yongjun Zhang > > Though Hive should be fixed not to access DFSClient which is private to > HADOOP, removing the throws added by HADOOP-14104 is a quicker solution to > unblock hive. > Hive code > {code} > private boolean isEncryptionEnabled(DFSClient client, Configuration conf) { > try { > DFSClient.class.getMethod("isHDFSEncryptionEnabled"); > } catch (NoSuchMethodException e) { > // the method is available since Hadoop-2.7.1 > // if we run with an older Hadoop, check this ourselves > return !conf.getTrimmed(DFSConfigKeys.DFS_ENCRYPTION_KEY_PROVIDER_URI, > "").isEmpty(); > } > return client.isHDFSEncryptionEnabled(); > } > {code} -- This message was sent by Atlassian JIRA (v6.3.15#6346) --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-issues-h...@hadoop.apache.org