You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by cd...@apache.org on 2008/11/12 23:58:04 UTC

svn commit: r713541 - in /hadoop/core/trunk: CHANGES.txt src/mapred/org/apache/hadoop/mapred/MultiFileSplit.java

Author: cdouglas
Date: Wed Nov 12 14:58:04 2008
New Revision: 713541

URL: http://svn.apache.org/viewvc?rev=713541&view=rev
Log:
HADOOP-4500. Fix MultiFileSplit to get the FileSystem from the relevant
path rather than the JobClient. Contributed by Joydeep Sen Sarma.

Modified:
    hadoop/core/trunk/CHANGES.txt
    hadoop/core/trunk/src/mapred/org/apache/hadoop/mapred/MultiFileSplit.java

Modified: hadoop/core/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/CHANGES.txt?rev=713541&r1=713540&r2=713541&view=diff
==============================================================================
--- hadoop/core/trunk/CHANGES.txt (original)
+++ hadoop/core/trunk/CHANGES.txt Wed Nov 12 14:58:04 2008
@@ -136,6 +136,9 @@
     HADOOP-4566. Deploy new hive code to support more types.
     (Zheng Shao via dhruba)
 
+    HADOOP-4500. Fix MultiFileSplit to get the FileSystem from the relevant
+    path rather than the JobClient. (Joydeep Sen Sarma via cdouglas)
+
 Release 0.19.0 - Unreleased
 
   INCOMPATIBLE CHANGES

Modified: hadoop/core/trunk/src/mapred/org/apache/hadoop/mapred/MultiFileSplit.java
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/src/mapred/org/apache/hadoop/mapred/MultiFileSplit.java?rev=713541&r1=713540&r2=713541&view=diff
==============================================================================
--- hadoop/core/trunk/src/mapred/org/apache/hadoop/mapred/MultiFileSplit.java (original)
+++ hadoop/core/trunk/src/mapred/org/apache/hadoop/mapred/MultiFileSplit.java Wed Nov 12 14:58:04 2008
@@ -90,9 +90,8 @@
 
   public String[] getLocations() throws IOException {
     HashSet<String> hostSet = new HashSet<String>();
-    JobClient jClient = new JobClient(job);
-    FileSystem fs = jClient.getFs();
     for (Path file : paths) {
+      FileSystem fs = file.getFileSystem(job);
       FileStatus status = fs.getFileStatus(file);
       BlockLocation[] blkLocations = fs.getFileBlockLocations(status,
                                           0, status.getLen());