From 1789c7c8c0fe0b9e6738fe2180c81c65bf7b75f2 Mon Sep 17 00:00:00 2001 From: jianghuazhu <740087514@qq.com> Date: Fri, 1 Oct 2021 10:30:41 +0800 Subject: [PATCH] HDFS-16238.Improve comments related to EncryptionZoneManager. (#3483) Co-authored-by: zhujianghua Reviewed-by: He Xiaoqiao Reviewed-by: Viraj Jasani --- .../namenode/EncryptionZoneManager.java | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/EncryptionZoneManager.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/EncryptionZoneManager.java index 6ab22e6aaa2..be465afb6e0 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/EncryptionZoneManager.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/EncryptionZoneManager.java @@ -616,8 +616,8 @@ public class EncryptionZoneManager { /** * Resolves the path to inode id, then check if it's the same as the inode id * passed in. This is necessary to filter out zones in snapshots. - * @param zoneId - * @param zonePath + * @param zoneId of the encryption zone + * @param zonePath encryption zone inode path * @return true if path resolve to the id, false if not. * @throws AccessControlException * @throws ParentNotDirectoryException @@ -645,8 +645,8 @@ public class EncryptionZoneManager { /** * Re-encrypts the given encryption zone path. If the given path is not the * root of an encryption zone, an exception is thrown. - * @param zoneIIP - * @param keyVersionName + * @param zoneIIP encryption zone inodes in the path containing the file + * @param keyVersionName encryption zone version * @throws IOException */ List reencryptEncryptionZone(final INodesInPath zoneIIP, @@ -677,7 +677,7 @@ public class EncryptionZoneManager { * Cancels the currently-running re-encryption of the given encryption zone. * If the given path is not the root of an encryption zone, * an exception is thrown. - * @param zoneIIP + * @param zoneIIP encryption zone inodes in the path containing the file * @throws IOException */ List cancelReencryptEncryptionZone(final INodesInPath zoneIIP) @@ -700,7 +700,8 @@ public class EncryptionZoneManager { * Cursor-based listing of zone re-encryption status. *

* Called while holding the FSDirectory lock. - * @param prevId + * @param prevId for a given encryption zone id, a larger and more + * encryption zone can be found * @throws IOException */ BatchedListEntries listReencryptionStatus( @@ -742,8 +743,8 @@ public class EncryptionZoneManager { /** * Return whether an INode is an encryption zone root. - * @param inode - * @param name + * @param inode of the encryption zone inode + * @param name the path name of the encrypted zone inode * @return true when INode is an encryption zone root else false * @throws FileNotFoundException */ @@ -767,7 +768,7 @@ public class EncryptionZoneManager { * Return whether an INode is an encryption zone root. * * @param inode the zone inode - * @param name + * @param name the path name of the encrypted zone inode * @throws IOException if the inode is not a directory, * or is a directory but not the root of an EZ. */