HBASE-9139 Independent timeout configuration for rpc channel between cluster nodes (Julian Zhou)

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1513337 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
larsh 2013-08-13 04:06:21 +00:00
parent 82ddf0da03
commit 41bf91e43d
3 changed files with 20 additions and 2 deletions

View File

@ -651,6 +651,16 @@ public final class HConstants {
*/
public static int DEFAULT_HBASE_RPC_TIMEOUT = 60000;
/**
* timeout for short operation RPC
*/
public static String HBASE_RPC_SHORTOPERATION_TIMEOUT_KEY = "hbase.rpc.shortoperation.timeout";
/**
* Default value of {@link #HBASE_RPC_SHORTOPERATION_TIMEOUT_KEY}
*/
public static int DEFAULT_HBASE_RPC_SHORTOPERATION_TIMEOUT = 10000;
/**
* Value indicating the server name was saved with no sequence number.
*/

View File

@ -675,6 +675,14 @@ possible configurations would overwhelm and obscure the important.
take for a remote call to time out. It uses pings to check connections
but will eventually throw a TimeoutException.</description>
</property>
<property>
<name>hbase.rpc.shortoperation.timeout</name>
<value>10000</value>
<description>This is another version of "hbase.rpc.timeout". For those RPC operation
within cluster, we rely on this configuration to set a short timeout limitation
for short operation. For example, short rpc timeout for region server's trying
to report to active master can benefit quicker master failover process.</description>
</property>
<property>
<name>hbase.ipc.client.tcpnodelay</name>
<value>true</value>

View File

@ -521,8 +521,8 @@ public class HRegionServer implements ClientProtos.ClientService.BlockingInterfa
"hbase.regionserver.numregionstoreport", 10);
this.rpcTimeout = conf.getInt(
HConstants.HBASE_RPC_TIMEOUT_KEY,
HConstants.DEFAULT_HBASE_RPC_TIMEOUT);
HConstants.HBASE_RPC_SHORTOPERATION_TIMEOUT_KEY,
HConstants.DEFAULT_HBASE_RPC_SHORTOPERATION_TIMEOUT);
this.abortRequested = false;
this.stopped = false;