MAPREDUCE-3811. Made jobclient-to-AM retries configurable. Contributed by Siddharth Seth.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1241285 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Arun Murthy 2012-02-07 00:20:36 +00:00
parent 75d2d6185e
commit 8dbf374f16
4 changed files with 20 additions and 1 deletions

View File

@ -268,6 +268,9 @@ Release 0.23.1 - Unreleased
MAPREDUCE-3756. Made single shuffle limit configurable. (Hitesh Shah via
acmurthy)
MAPREDUCE-3811. Made jobclient-to-AM retries configurable. (sseth via
acmurthy)
BUG FIXES
MAPREDUCE-3221. Reenabled the previously ignored test in TestSubmitJob

View File

@ -320,6 +320,13 @@ public interface MRJobConfig {
public static final String MR_AM_PREFIX = MR_PREFIX + "am.";
/** The number of client retires to the AM - before reconnecting to the RM
* to fetch Application State.
*/
public static final String MR_CLIENT_TO_AM_IPC_MAX_RETRIES =
MR_PREFIX + "client-am.ipc.max-retries";
public static final int DEFAULT_MR_CLIENT_TO_AM_IPC_MAX_RETRIES = 3;
/** The staging directory for map reduce.*/
public static final String MR_AM_STAGING_DIR =
MR_AM_PREFIX+"staging-dir";

View File

@ -1255,4 +1255,11 @@
heartbeats to the ResourceManager</description>
</property>
<property>
<name>yarn.app.mapreduce.client-am.ipc.max-retries</name>
<value>1</value>
<description>The number of client retries to the AM - before reconnecting
to the RM to fetch Application Status.</description>
</property>
</configuration>

View File

@ -101,7 +101,9 @@ public class ClientServiceDelegate {
this.conf = new Configuration(conf); // Cloning for modifying.
// For faster redirects from AM to HS.
this.conf.setInt(
CommonConfigurationKeysPublic.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY, 3);
CommonConfigurationKeysPublic.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY,
this.conf.getInt(MRJobConfig.MR_CLIENT_TO_AM_IPC_MAX_RETRIES,
MRJobConfig.DEFAULT_MR_CLIENT_TO_AM_IPC_MAX_RETRIES));
this.rm = rm;
this.jobId = jobId;
this.historyServerProxy = historyServerProxy;