HDFS-13114. CryptoAdmin#ReencryptZoneCommand should resolve Namespace info from path. Contributed by Hanisha Koneru.
Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/891182d8 Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/891182d8 Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/891182d8 Branch: refs/heads/YARN-7055 Commit: 891182d8a2652c8f3bc9c810ff4bef9d62bca36d Parents: 03b1a33 Author: Xiaoyu Yao <[email protected]> Authored: Tue Feb 27 19:50:00 2018 -0800 Committer: Rohith Sharma K S <[email protected]> Committed: Fri Mar 2 11:08:28 2018 +0530 ---------------------------------------------------------------------- .../src/main/java/org/apache/hadoop/hdfs/tools/CryptoAdmin.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hadoop/blob/891182d8/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CryptoAdmin.java ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CryptoAdmin.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CryptoAdmin.java index 4b0b083..5f4e738 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CryptoAdmin.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CryptoAdmin.java @@ -337,8 +337,8 @@ public class CryptoAdmin extends Configured implements Tool { action = ReencryptAction.CANCEL; } - final HdfsAdmin admin = - new HdfsAdmin(FileSystem.getDefaultUri(conf), conf); + Path p = new Path(path); + final HdfsAdmin admin = new HdfsAdmin(p.toUri(), conf); try { admin.reencryptEncryptionZone(new Path(path), action); System.out.println("re-encrypt command successfully submitted for " --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
