HADOOP-10127. Add ipc.client.connect.retry.interval to control the frequency of connection retries (Karthik Kambatla via Sandy Ryza)
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1547626 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
5afc1242ea
commit
f7fe50d55f
@ -390,6 +390,9 @@ Release 2.4.0 - UNRELEASED
|
||||
|
||||
HADOOP-10126. LightWeightGSet log message is confusing. (Vinay via suresh)
|
||||
|
||||
HADOOP-10127. Add ipc.client.connect.retry.interval to control the frequency
|
||||
of connection retries (Karthik Kambatla via Sandy Ryza)
|
||||
|
||||
OPTIMIZATIONS
|
||||
|
||||
HADOOP-9748. Reduce blocking on UGI.ensureInitialized (daryn)
|
||||
|
@ -192,6 +192,11 @@ public class CommonConfigurationKeysPublic {
|
||||
/** Default value for IPC_CLIENT_CONNECT_MAX_RETRIES_KEY */
|
||||
public static final int IPC_CLIENT_CONNECT_MAX_RETRIES_DEFAULT = 10;
|
||||
/** See <a href="{@docRoot}/../core-default.html">core-default.xml</a> */
|
||||
public static final String IPC_CLIENT_CONNECT_RETRY_INTERVAL_KEY =
|
||||
"ipc.client.connect.retry.interval";
|
||||
/** Default value for IPC_CLIENT_CONNECT_RETRY_INTERVAL_KEY */
|
||||
public static final int IPC_CLIENT_CONNECT_RETRY_INTERVAL_DEFAULT = 1000;
|
||||
/** See <a href="{@docRoot}/../core-default.html">core-default.xml</a> */
|
||||
public static final String IPC_CLIENT_CONNECT_MAX_RETRIES_ON_SOCKET_TIMEOUTS_KEY =
|
||||
"ipc.client.connect.max.retries.on.timeouts";
|
||||
/** Default value for IPC_CLIENT_CONNECT_MAX_RETRIES_ON_SOCKET_TIMEOUTS_KEY */
|
||||
|
@ -1562,8 +1562,13 @@ static ConnectionId getConnectionId(InetSocketAddress addr,
|
||||
final int max = conf.getInt(
|
||||
CommonConfigurationKeysPublic.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY,
|
||||
CommonConfigurationKeysPublic.IPC_CLIENT_CONNECT_MAX_RETRIES_DEFAULT);
|
||||
final int retryInterval = conf.getInt(
|
||||
CommonConfigurationKeysPublic.IPC_CLIENT_CONNECT_RETRY_INTERVAL_KEY,
|
||||
CommonConfigurationKeysPublic
|
||||
.IPC_CLIENT_CONNECT_RETRY_INTERVAL_DEFAULT);
|
||||
|
||||
connectionRetryPolicy = RetryPolicies.retryUpToMaximumCountWithFixedSleep(
|
||||
max, 1, TimeUnit.SECONDS);
|
||||
max, retryInterval, TimeUnit.MILLISECONDS);
|
||||
}
|
||||
|
||||
boolean doPing =
|
||||
|
@ -618,6 +618,14 @@
|
||||
</description>
|
||||
</property>
|
||||
|
||||
<property>
|
||||
<name>ipc.client.connect.retry.interval</name>
|
||||
<value>1000</value>
|
||||
<description>Indicates the number of milliseconds a client will wait for
|
||||
before retrying to establish a server connection.
|
||||
</description>
|
||||
</property>
|
||||
|
||||
<property>
|
||||
<name>ipc.client.connect.timeout</name>
|
||||
<value>20000</value>
|
||||
|
Loading…
Reference in New Issue
Block a user