You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by la...@apache.org on 2013/08/13 06:08:46 UTC

svn commit: r1513338 - in /hbase/branches/0.95: hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java hbase-common/src/main/resources/hbase-default.xml hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java

Author: larsh
Date: Tue Aug 13 04:08:45 2013
New Revision: 1513338

URL: http://svn.apache.org/r1513338
Log:
HBASE-9139 Independent timeout configuration for rpc channel between cluster nodes (Julian Zhou)

Modified:
    hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java
    hbase/branches/0.95/hbase-common/src/main/resources/hbase-default.xml
    hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java

Modified: hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java?rev=1513338&r1=1513337&r2=1513338&view=diff
==============================================================================
--- hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java (original)
+++ hbase/branches/0.95/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java Tue Aug 13 04:08:45 2013
@@ -652,6 +652,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.
    */
   public static final long NO_SEQNUM = -1;

Modified: hbase/branches/0.95/hbase-common/src/main/resources/hbase-default.xml
URL: http://svn.apache.org/viewvc/hbase/branches/0.95/hbase-common/src/main/resources/hbase-default.xml?rev=1513338&r1=1513337&r2=1513338&view=diff
==============================================================================
--- hbase/branches/0.95/hbase-common/src/main/resources/hbase-default.xml (original)
+++ hbase/branches/0.95/hbase-common/src/main/resources/hbase-default.xml Tue Aug 13 04:08:45 2013
@@ -676,6 +676,14 @@ possible configurations would overwhelm 
         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>
     <description>Set no delay on rpc socket connections.  See

Modified: hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java?rev=1513338&r1=1513337&r2=1513338&view=diff
==============================================================================
--- hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java (original)
+++ hbase/branches/0.95/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java Tue Aug 13 04:08:45 2013
@@ -520,8 +520,8 @@ public class HRegionServer implements Cl
       "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;