Browse Source

HADOOP-3706. Fix a ClassLoader issue in the mapred.join Parser that
prevents it from loading user-specified InputFormats.
Contributed by Jingkei Ly.


git-svn-id: https://svn.apache.org/repos/asf/hadoop/core/trunk@675078 13f79535-47bb-0310-9956-ffa450edef68

Christopher Douglas 17 years ago
parent
commit
981fa44e1c
2 changed files with 6 additions and 2 deletions
  1. 4 0
      CHANGES.txt
  2. 2 2
      src/mapred/org/apache/hadoop/mapred/join/Parser.java

+ 4 - 0
CHANGES.txt

@@ -788,6 +788,10 @@ Release 0.18.0 - Unreleased
     HADOOP-3630. Fix NullPointerException in CompositeRecordReader from empty
     sources (cdouglas)
 
+    HADOOP-3706. Fix a ClassLoader issue in the mapred.join Parser that
+    prevents it from loading user-specified InputFormats.
+    (Jingkei Ly via cdouglas)
+
 Release 0.17.2 - Unreleased
 
   BUG FIXES

+ 2 - 2
src/mapred/org/apache/hadoop/mapred/join/Parser.java

@@ -267,8 +267,8 @@ public class Parser {
         Token t = i.next();
         if (TType.COMMA.equals(t.getType())) {
           try {
-            inf = (InputFormat)ReflectionUtils.newInstance(
-                Class.forName(sb.toString()).asSubclass(InputFormat.class),
+          	inf = (InputFormat)ReflectionUtils.newInstance(
+          			job.getClassByName(sb.toString()),
                 job);
           } catch (ClassNotFoundException e) {
             throw (IOException)new IOException().initCause(e);