소스 검색

MAPREDUCE-7125. JobResourceUploader creates LocalFileSystem when it's not necessary. (Peter Cseh via wangda)

Change-Id: I1aa720ed03739f6f4abeec46f6068e2ab332987a
Wangda Tan 6 년 전
부모
커밋
230d90c5b9

+ 1 - 1
hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/JobResourceUploader.java

@@ -855,8 +855,8 @@ class JobResourceUploader {
       throw new IllegalArgumentException(e);
     }
     Path path = new Path(pathURI);
-    FileSystem localFs = FileSystem.getLocal(conf);
     if (pathURI.getScheme() == null) {
+      FileSystem localFs = FileSystem.getLocal(conf);
       // default to the local file system
       // check if the file exists or not first
       localFs.getFileStatus(path);