You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pig.apache.org by da...@apache.org on 2014/08/05 02:12:55 UTC
svn commit: r1615826 - in /pig/trunk: CHANGES.txt build.xml
src/org/apache/pig/backend/hadoop/executionengine/tez/TezLauncher.java
Author: daijy
Date: Tue Aug 5 00:12:55 2014
New Revision: 1615826
URL: http://svn.apache.org/r1615826
Log:
PIG-4008: Pig code change to enable Tez Local mode
Modified:
pig/trunk/CHANGES.txt
pig/trunk/build.xml
pig/trunk/src/org/apache/pig/backend/hadoop/executionengine/tez/TezLauncher.java
Modified: pig/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/pig/trunk/CHANGES.txt?rev=1615826&r1=1615825&r2=1615826&view=diff
==============================================================================
--- pig/trunk/CHANGES.txt (original)
+++ pig/trunk/CHANGES.txt Tue Aug 5 00:12:55 2014
@@ -24,6 +24,8 @@ INCOMPATIBLE CHANGES
IMPROVEMENTS
+PIG-4008: Pig code change to enable Tez Local mode (airbots via daijy)
+
PIG-4091: Predicate pushdown for ORC (rohini via daijy)
PIG-4077: Some fixes and e2e test for OrcStorage (rohini)
Modified: pig/trunk/build.xml
URL: http://svn.apache.org/viewvc/pig/trunk/build.xml?rev=1615826&r1=1615825&r2=1615826&view=diff
==============================================================================
--- pig/trunk/build.xml (original)
+++ pig/trunk/build.xml Tue Aug 5 00:12:55 2014
@@ -753,6 +753,8 @@
<fileset dir="${ivy.lib.dir}" includes="avro-mapred-*.jar"/>
<fileset dir="${ivy.lib.dir}" includes="hive-shims-0.*.jar"/>
<fileset dir="${ivy.lib.dir}" includes="hbase-*hadoop2.jar"/>
+ <fileset dir="${ivy.lib.dir}" includes="tez-*.jar"/>
+ <fileset dir="${ivy.lib.dir}" includes="commons-collections4-*.jar"/>
</copy>
<copy file="${output.jarfile.core}" tofile="${output.jarfile.backcompat-core-h2}"/>
<mkdir dir="${legacy.dir}" />
Modified: pig/trunk/src/org/apache/pig/backend/hadoop/executionengine/tez/TezLauncher.java
URL: http://svn.apache.org/viewvc/pig/trunk/src/org/apache/pig/backend/hadoop/executionengine/tez/TezLauncher.java?rev=1615826&r1=1615825&r2=1615826&view=diff
==============================================================================
--- pig/trunk/src/org/apache/pig/backend/hadoop/executionengine/tez/TezLauncher.java (original)
+++ pig/trunk/src/org/apache/pig/backend/hadoop/executionengine/tez/TezLauncher.java Tue Aug 5 00:12:55 2014
@@ -60,6 +60,7 @@ import org.apache.tez.common.TezUtils;
import org.apache.tez.dag.api.TezConfiguration;
import org.apache.tez.dag.api.Vertex;
import org.apache.tez.dag.api.client.DAGStatus;
+import org.apache.tez.runtime.library.api.TezRuntimeConfiguration;
/**
* Main class that launches pig for Tez
@@ -74,6 +75,11 @@ public class TezLauncher extends Launche
@Override
public PigStats launchPig(PhysicalPlan php, String grpName, PigContext pc) throws Exception {
+ if (pc.getExecType().isLocal()) {
+ pc.getProperties().setProperty(TezConfiguration.TEZ_LOCAL_MODE, "true");
+ pc.getProperties().setProperty(TezRuntimeConfiguration.TEZ_RUNTIME_OPTIMIZE_LOCAL_FETCH, "true");
+ pc.getProperties().setProperty("tez.ignore.lib.uris", "true");
+ }
Configuration conf = ConfigurationUtil.toConfiguration(pc.getProperties(), true);
if (pc.defaultParallel == -1 && !conf.getBoolean(PigConfiguration.TEZ_AUTO_PARALLELISM, true)) {
pc.defaultParallel = 1;