You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-commits@hadoop.apache.org by cn...@apache.org on 2013/10/16 22:23:14 UTC
svn commit: r1532888 - in
/hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs:
CHANGES-HDFS-4949.txt
src/main/java/org/apache/hadoop/hdfs/tools/CacheAdmin.java
src/test/resources/testCacheAdminConf.xml
Author: cnauroth
Date: Wed Oct 16 20:23:14 2013
New Revision: 1532888
URL: http://svn.apache.org/r1532888
Log:
HDFS-5373. hdfs cacheadmin -addDirective short usage does not mention -replication parameter. Contributed by Chris Nauroth.
Modified:
hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-4949.txt
hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CacheAdmin.java
hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml
Modified: hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-4949.txt
URL: http://svn.apache.org/viewvc/hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-4949.txt?rev=1532888&r1=1532887&r2=1532888&view=diff
==============================================================================
--- hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-4949.txt (original)
+++ hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/CHANGES-HDFS-4949.txt Wed Oct 16 20:23:14 2013
@@ -93,3 +93,6 @@ HDFS-4949 (Unreleased)
HDFS-5348. Fix error message when dfs.datanode.max.locked.memory is
improperly configured. (Colin Patrick McCabe)
+
+ HDFS-5373. hdfs cacheadmin -addDirective short usage does not mention
+ -replication parameter. (cnauroth)
Modified: hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CacheAdmin.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CacheAdmin.java?rev=1532888&r1=1532887&r2=1532888&view=diff
==============================================================================
--- hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CacheAdmin.java (original)
+++ hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools/CacheAdmin.java Wed Oct 16 20:23:14 2013
@@ -131,7 +131,8 @@ public class CacheAdmin extends Configur
@Override
public String getShortUsage() {
- return "[" + getName() + " -path <path> -pool <pool-name>]\n";
+ return "[" + getName() +
+ " -path <path> -replication <replication> -pool <pool-name>]\n";
}
@Override
Modified: hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml
URL: http://svn.apache.org/viewvc/hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml?rev=1532888&r1=1532887&r2=1532888&view=diff
==============================================================================
--- hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml (original)
+++ hadoop/common/branches/HDFS-4949/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml Wed Oct 16 20:23:14 2013
@@ -167,6 +167,7 @@
<cache-admin-command>-addPool pool1</cache-admin-command>
<cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command>
<cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command>
+ <cache-admin-command>-addDirective -path /baz -replication 2 -pool pool1</cache-admin-command>
<cache-admin-command>-listDirectives -pool pool1</cache-admin-command>
</test-commands>
<cleanup-commands>
@@ -175,7 +176,7 @@
<comparators>
<comparator>
<type>SubstringComparator</type>
- <expected-output>Found 2 entries</expected-output>
+ <expected-output>Found 3 entries</expected-output>
</comparator>
<comparator>
<type>SubstringComparator</type>
@@ -185,6 +186,10 @@
<type>SubstringComparator</type>
<expected-output>2 pool1 /bar</expected-output>
</comparator>
+ <comparator>
+ <type>SubstringComparator</type>
+ <expected-output>3 pool1 /baz</expected-output>
+ </comparator>
</comparators>
</test>