Pārlūkot izejas kodu

HDFS-10404. Fix formatting of CacheAdmin command usage help text (Yiqun Lin via cmccabe)

(cherry picked from commit 7cd5ae62f639a857f24f5463f2aefc099c631a14)
Colin Patrick Mccabe 9 gadi atpakaļ
vecāks
revīzija
6ebb92c9c1

+ 4 - 2
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CacheAdmin.java

@@ -443,7 +443,8 @@ public class CacheAdmin extends Configured implements Tool {
     @Override
     public String getShortUsage() {
       return "[" + getName()
-          + " [-stats] [-path <path>] [-pool <pool>] [-id <id>]\n";
+          + " [-stats] [-path <path>] [-pool <pool>] [-id <id>]"
+          + "]\n";
     }
 
     @Override
@@ -554,7 +555,8 @@ public class CacheAdmin extends Configured implements Tool {
     public String getShortUsage() {
       return "[" + NAME + " <name> [-owner <owner>] " +
           "[-group <group>] [-mode <mode>] [-limit <limit>] " +
-          "[-maxTtl <maxTtl>]\n";
+          "[-maxTtl <maxTtl>]" +
+          "]\n";
     }
 
     @Override

+ 1 - 1
hadoop-hdfs-project/hadoop-hdfs/src/site/markdown/CentralizedCacheManagement.md

@@ -157,7 +157,7 @@ List cache directives.
 
 #### addPool
 
-Usage: `hdfs cacheadmin -addPool <name> [-owner <owner>] [-group <group>] [-mode <mode>] [-limit <limit>] [-maxTtl <maxTtl`\>
+Usage: `hdfs cacheadmin -addPool <name> [-owner <owner>] [-group <group>] [-mode <mode>] [-limit <limit>] [-maxTtl <maxTtl>]`
 
 Add a new cache pool.
 

+ 2 - 2
hadoop-hdfs-project/hadoop-hdfs/src/site/markdown/HDFSCommands.md

@@ -312,10 +312,10 @@ Usage:
 
     hdfs cacheadmin [-addDirective -path <path> -pool <pool-name> [-force] [-replication <replication>] [-ttl <time-to-live>]]
     hdfs cacheadmin [-modifyDirective -id <id> [-path <path>] [-force] [-replication <replication>] [-pool <pool-name>] [-ttl <time-to-live>]]
-    hdfs cacheadmin [-listDirectives [-stats] [-path <path>] [-pool <pool>] [-id <id>]
+    hdfs cacheadmin [-listDirectives [-stats] [-path <path>] [-pool <pool>] [-id <id>]]
     hdfs cacheadmin [-removeDirective <id>]
     hdfs cacheadmin [-removeDirectives -path <path>]
-    hdfs cacheadmin [-addPool <name> [-owner <owner>] [-group <group>] [-mode <mode>] [-limit <limit>] [-maxTtl <maxTtl>]
+    hdfs cacheadmin [-addPool <name> [-owner <owner>] [-group <group>] [-mode <mode>] [-limit <limit>] [-maxTtl <maxTtl>]]
     hdfs cacheadmin [-modifyPool <name> [-owner <owner>] [-group <group>] [-mode <mode>] [-limit <limit>] [-maxTtl <maxTtl>]]
     hdfs cacheadmin [-removePool <name>]
     hdfs cacheadmin [-listPools [-stats] [<name>]]