You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tez.apache.org by bi...@apache.org on 2013/04/26 04:01:15 UTC
svn commit: r1476023 - in /incubator/tez/branches/TEZ-1:
tez-dag-api/src/main/java/org/apache/tez/dag/api/TezConfiguration.java
tez-dag/src/main/java/org/apache/tez/dag/app/dag/impl/VertexImpl.java
Author: bikas
Date: Fri Apr 26 02:01:15 2013
New Revision: 1476023
URL: http://svn.apache.org/r1476023
Log:
TEZ-40. BipartiteSlowStartVertexScheduler configs should come from TezConfiguration (bikas)
Modified:
incubator/tez/branches/TEZ-1/tez-dag-api/src/main/java/org/apache/tez/dag/api/TezConfiguration.java
incubator/tez/branches/TEZ-1/tez-dag/src/main/java/org/apache/tez/dag/app/dag/impl/VertexImpl.java
Modified: incubator/tez/branches/TEZ-1/tez-dag-api/src/main/java/org/apache/tez/dag/api/TezConfiguration.java
URL: http://svn.apache.org/viewvc/incubator/tez/branches/TEZ-1/tez-dag-api/src/main/java/org/apache/tez/dag/api/TezConfiguration.java?rev=1476023&r1=1476022&r2=1476023&view=diff
==============================================================================
--- incubator/tez/branches/TEZ-1/tez-dag-api/src/main/java/org/apache/tez/dag/api/TezConfiguration.java (original)
+++ incubator/tez/branches/TEZ-1/tez-dag-api/src/main/java/org/apache/tez/dag/api/TezConfiguration.java Fri Apr 26 02:01:15 2013
@@ -79,8 +79,20 @@ public class TezConfiguration extends Co
public static final String DAG_AM_RESOURCE_CPU_VCORES = DAG_AM_PREFIX
+ "resource.cpu.vcores";
public static final int DEFAULT_DAG_AM_RESOURCE_CPU_VCORES = 1;
+
+ public static final String
+ SLOWSTART_VERTEX_SCHEDULER_MIN_SRC_FRACTION = TEZ_PREFIX
+ + "slowstart-vertex-scheduler.min-src-fraction";
+ public static final float
+ SLOWSTART_VERTEX_SCHEDULER_MIN_SRC_FRACTION_DEFAULT = 0.5f;
- private static final String TEZ_CONF_DIR_ENV = "TEZ_CONF_DIR";
+ public static final String
+ SLOWSTART_VERTEX_SCHEDULER_MAX_SRC_FRACTION = TEZ_PREFIX
+ + "slowstart-vertex-scheduler.max-src-fraction";
+ public static final float
+ SLOWSTART_VERTEX_SCHEDULER_MAX_SRC_FRACTION_DEFAULT = 0.8f;
+
+private static final String TEZ_CONF_DIR_ENV = "TEZ_CONF_DIR";
private static final String TEZ_HOME_ENV = "TEZ_HOME";
public static final String TEZ_APPLICATION_CLASSPATH = TEZ_PREFIX
Modified: incubator/tez/branches/TEZ-1/tez-dag/src/main/java/org/apache/tez/dag/app/dag/impl/VertexImpl.java
URL: http://svn.apache.org/viewvc/incubator/tez/branches/TEZ-1/tez-dag/src/main/java/org/apache/tez/dag/app/dag/impl/VertexImpl.java?rev=1476023&r1=1476022&r2=1476023&view=diff
==============================================================================
--- incubator/tez/branches/TEZ-1/tez-dag/src/main/java/org/apache/tez/dag/app/dag/impl/VertexImpl.java (original)
+++ incubator/tez/branches/TEZ-1/tez-dag/src/main/java/org/apache/tez/dag/app/dag/impl/VertexImpl.java Fri Apr 26 02:01:15 2013
@@ -784,11 +784,16 @@ public class VertexImpl implements org.a
// setup vertex scheduler
// TODO this needs to consider data size and perhaps API.
// Currently implicitly BIPARTITE is the only edge type
- // TODO TEZ-40 config from TeztConfiguration
- vertex.vertexScheduler = new
- BipartiteSlowStartVertexScheduler(vertex,
- 0.5f,
- 0.8f);
+ vertex.vertexScheduler = new BipartiteSlowStartVertexScheduler(
+ vertex,
+ vertex.conf
+ .getFloat(
+ TezConfiguration.SLOWSTART_VERTEX_SCHEDULER_MIN_SRC_FRACTION,
+ TezConfiguration.SLOWSTART_VERTEX_SCHEDULER_MIN_SRC_FRACTION_DEFAULT),
+ vertex.conf
+ .getFloat(
+ TezConfiguration.SLOWSTART_VERTEX_SCHEDULER_MAX_SRC_FRACTION,
+ TezConfiguration.SLOWSTART_VERTEX_SCHEDULER_MAX_SRC_FRACTION_DEFAULT));
} else {
// schedule all tasks upon vertex start
vertex.vertexScheduler = new ImmediateStartVertexScheduler(vertex);