You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by br...@apache.org on 2014/08/18 18:09:45 UTC
svn commit: r1618646 -
/hive/branches/spark/ql/src/java/org/apache/hadoop/hive/ql/exec/spark/SparkPlanGenerator.java
Author: brock
Date: Mon Aug 18 16:09:45 2014
New Revision: 1618646
URL: http://svn.apache.org/r1618646
Log:
HIVE-7763 - Failed to qeury TABLESAMPLE on empty bucket table [Spark Branch] (Chengxiang via Brock)
Modified:
hive/branches/spark/ql/src/java/org/apache/hadoop/hive/ql/exec/spark/SparkPlanGenerator.java
Modified: hive/branches/spark/ql/src/java/org/apache/hadoop/hive/ql/exec/spark/SparkPlanGenerator.java
URL: http://svn.apache.org/viewvc/hive/branches/spark/ql/src/java/org/apache/hadoop/hive/ql/exec/spark/SparkPlanGenerator.java?rev=1618646&r1=1618645&r2=1618646&view=diff
==============================================================================
--- hive/branches/spark/ql/src/java/org/apache/hadoop/hive/ql/exec/spark/SparkPlanGenerator.java (original)
+++ hive/branches/spark/ql/src/java/org/apache/hadoop/hive/ql/exec/spark/SparkPlanGenerator.java Mon Aug 18 16:09:45 2014
@@ -158,7 +158,7 @@ public class SparkPlanGenerator {
return inputFormatClass;
}
- private SparkTran generate(BaseWork bw) throws IOException, HiveException {
+ private SparkTran generate(BaseWork bw) throws Exception {
// initialize stats publisher if necessary
if (bw.isGatheringStats()) {
StatsPublisher statsPublisher;
@@ -183,9 +183,14 @@ public class SparkPlanGenerator {
}
}
- private MapTran generate(MapWork mw) throws IOException {
+ private MapTran generate(MapWork mw) throws Exception {
JobConf newJobConf = new JobConf(jobConf);
MapTran result = new MapTran();
+
+ List<Path> inputPaths = Utilities.getInputPaths(newJobConf, mw,
+ scratchDir, context, false);
+ Utilities.setInputPaths(newJobConf, inputPaths);
+
Utilities.setMapWork(newJobConf, mw, scratchDir, true);
Utilities.createTmpDirs(newJobConf, mw);
newJobConf.set("mapred.mapper.class", ExecMapper.class.getName());