[
https://issues.apache.org/jira/browse/HIVE-487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12734749#action_12734749
]
Todd Lipcon commented on HIVE-487:
----------------------------------
A couple thoughts:
- Does the same compiled jar truly work in all versions of Hadoop between 0.17
and 0.19? That is to say, can we consider an option in which we use some
build.xml rules to, depending on the value of a hadoop.version variable, swap
between two implementations of the same .java file (one compatible with Jetty
5, one with Jetty 6)? Then in the build product we could simply include two
jars and have the wrapper scripts swap between them based on version. If size
is a concern, the variant classes could be put in their own jar that would only
be a few KB.
- The reflection code in this patch is pretty messy. I mocked up an idea for a
slightly cleaner way to do it, and will attach it as a tarball momentarily. The
idea is to define our own interfaces which have the same methods as we need to
use in Jetty, and use a dynamic proxy to forward those invocations through to
the actual implementation class. Dynamically choosing between the two
interfaces is simple at runtime by simply checking that the method signatures
correspond. This is still dirty (and a bad role model for CS students ;-) ) but
it should reduce the number of Class.forName and .getMethod calls in the
wrapper class
> Hive does not compile with Hadoop 0.20.0
> ----------------------------------------
>
> Key: HIVE-487
> URL: https://issues.apache.org/jira/browse/HIVE-487
> Project: Hadoop Hive
> Issue Type: Bug
> Affects Versions: 0.3.0
> Reporter: Aaron Kimball
> Assignee: Justin Lynn
> Fix For: 0.4.0
>
> Attachments: HIVE-487-2.patch, hive-487-jetty-2.diff,
> hive-487-jetty.patch, hive-487.3.patch, hive-487.4.patch, HIVE-487.patch,
> jetty-patch.patch, junit-patch1.html
>
>
> Attempting to compile Hive with Hadoop 0.20.0 fails:
> aa...@jargon:~/src/ext/svn/hive-0.3.0$ ant -Dhadoop.version=0.20.0 package
> (several lines elided)
> compile:
> [echo] Compiling: hive
> [javac] Compiling 261 source files to
> /home/aaron/src/ext/svn/hive-0.3.0/build/ql/classes
> [javac]
> /home/aaron/src/ext/svn/hive-0.3.0/build/ql/java/org/apache/hadoop/hive/ql/exec/ExecDriver.java:94:
> cannot find symbol
> [javac] symbol : method getCommandLineConfig()
> [javac] location: class org.apache.hadoop.mapred.JobClient
> [javac] Configuration commandConf =
> JobClient.getCommandLineConfig();
> [javac] ^
> [javac]
> /home/aaron/src/ext/svn/hive-0.3.0/build/ql/java/org/apache/hadoop/hive/ql/io/HiveInputFormat.java:241:
> cannot find symbol
> [javac] symbol : method validateInput(org.apache.hadoop.mapred.JobConf)
> [javac] location: interface org.apache.hadoop.mapred.InputFormat
> [javac] inputFormat.validateInput(newjob);
> [javac] ^
> [javac] Note: Some input files use or override a deprecated API.
> [javac] Note: Recompile with -Xlint:deprecation for details.
> [javac] Note: Some input files use unchecked or unsafe operations.
> [javac] Note: Recompile with -Xlint:unchecked for details.
> [javac] 2 errors
> BUILD FAILED
> /home/aaron/src/ext/svn/hive-0.3.0/build.xml:145: The following error
> occurred while executing this line:
> /home/aaron/src/ext/svn/hive-0.3.0/ql/build.xml:135: Compile failed; see the
> compiler error output for details.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.