Browse Source

HDFS-9196. Fix TestWebHdfsContentLength. Contributed by Masatake Iwasaki.

Jing Zhao 9 years ago
parent
commit
239d119c67

+ 1 - 1
hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/web/WebHdfsFileSystem.java

@@ -212,7 +212,7 @@ public class WebHdfsFileSystem extends FileSystem
               failoverSleepMaxMillis);
     }
 
-    this.workingDir = makeQualified(getHomeDirectory());
+    this.workingDir = makeQualified(new Path(getHomeDirectoryString(ugi)));
     this.canRefreshDelegationToken = UserGroupInformation.isSecurityEnabled();
     this.disallowFallbackToInsecureCluster = !conf.getBoolean(
         CommonConfigurationKeys.IPC_CLIENT_FALLBACK_TO_SIMPLE_AUTH_ALLOWED_KEY,

+ 2 - 0
hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt

@@ -1967,6 +1967,8 @@ Release 2.8.0 - UNRELEASED
 
     HDFS-7899. Improve EOF error message (Jagadesh Kiran N via vinayakumarb)
 
+    HDFS-9196. Fix TestWebHdfsContentLength. (Masatake Iwasaki via jing9)
+
 Release 2.7.2 - UNRELEASED
 
   INCOMPATIBLE CHANGES