use of org.apache.hadoop.hive.ql.parse.spark.OptimizeSparkProcContext in project hive by apache.
the class SparkJoinOptimizer method process.
@Override
public Object process(Node nd, Stack<Node> stack, NodeProcessorCtx procCtx, Object... nodeOutputs) throws SemanticException {
OptimizeSparkProcContext context = (OptimizeSparkProcContext) procCtx;
HiveConf conf = context.getConf();
if (conf.getBoolVar(HiveConf.ConfVars.HIVE_AUTO_SORTMERGE_JOIN_TOMAPJOIN)) {
Object mapJoinOp = mapJoinOptimizer.process(nd, stack, procCtx, nodeOutputs);
if (mapJoinOp == null) {
smbJoinOptimizer.process(nd, stack, procCtx, nodeOutputs);
}
} else {
Object sortMergeJoinOp = smbJoinOptimizer.process(nd, stack, procCtx, nodeOutputs);
if (sortMergeJoinOp == null) {
mapJoinOptimizer.process(nd, stack, procCtx, nodeOutputs);
}
}
return null;
}
Aggregations