瀏覽代碼

MAPREDUCE-4307. TeraInputFormat calls FileSystem.getDefaultBlockSize() without a Path - Failure when using ViewFileSystem. Contributed by Ahmed Radwan

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1345552 13f79535-47bb-0310-9956-ffa450edef68
Eli Collins 13 年之前
父節點
當前提交
026a285d52

+ 3 - 0
hadoop-mapreduce-project/CHANGES.txt

@@ -39,6 +39,9 @@ Release 2.0.1-alpha - UNRELEASED
     MAPREDUCE-3493. Add the default mapreduce.shuffle.port property
     to mapred-default.xml (Madhukara Phatak via harsh)
 
+    MAPREDUCE-4307. TeraInputFormat calls FileSystem.getDefaultBlockSize()
+    without a Path - Failure when using ViewFileSystem. (Ahmed Radwan via eli)
+
 Release 2.0.0-alpha - UNRELEASED
 
   INCOMPATIBLE CHANGES

+ 1 - 1
hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/terasort/TeraInputFormat.java

@@ -212,7 +212,7 @@ public class TeraInputFormat extends FileInputFormat<Text,Text> {
     }
     FileSystem outFs = partFile.getFileSystem(conf);
     DataOutputStream writer = outFs.create(partFile, true, 64*1024, (short) 10, 
-                                           outFs.getDefaultBlockSize());
+                                           outFs.getDefaultBlockSize(partFile));
     for (int i = 0; i < samples; i++) {
       try {
         samplerReader[i].join();