hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject svn commit: r1231347 - /hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionThriftServer.java
Date Fri, 13 Jan 2012 22:23:52 GMT
Author: stack
Date: Fri Jan 13 22:23:52 2012
New Revision: 1231347

URL: http://svn.apache.org/viewvc?rev=1231347&view=rev
Log:
HBASE-5193 Use TBoundedThreadPoolServer in HRegionThriftServer

Modified:
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionThriftServer.java

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionThriftServer.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionThriftServer.java?rev=1231347&r1=1231346&r2=1231347&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionThriftServer.java
(original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionThriftServer.java
Fri Jan 13 22:23:52 2012
@@ -34,17 +34,18 @@ import org.apache.hadoop.hbase.NotServin
 import org.apache.hadoop.hbase.client.Get;
 import org.apache.hadoop.hbase.client.HTable;
 import org.apache.hadoop.hbase.client.Result;
-import org.apache.hadoop.hbase.thrift.ThriftServer;
-import org.apache.hadoop.hbase.thrift.ThriftUtilities;
 import org.apache.hadoop.hbase.thrift.generated.Hbase;
 import org.apache.hadoop.hbase.thrift.generated.IOError;
 import org.apache.hadoop.hbase.thrift.generated.TRowResult;
+import org.apache.hadoop.hbase.thrift.TBoundedThreadPoolServer;
+import org.apache.hadoop.hbase.thrift.TBoundedThreadPoolServer.Args;
+import org.apache.hadoop.hbase.thrift.ThriftServer;
+import org.apache.hadoop.hbase.thrift.ThriftUtilities;
 import org.apache.thrift.protocol.TBinaryProtocol;
 import org.apache.thrift.protocol.TCompactProtocol;
 import org.apache.thrift.protocol.TProtocolFactory;
 import org.apache.thrift.server.TNonblockingServer;
 import org.apache.thrift.server.TServer;
-import org.apache.thrift.server.TThreadPoolServer;
 import org.apache.thrift.transport.TFramedTransport;
 import org.apache.thrift.transport.TNonblockingServerSocket;
 import org.apache.thrift.transport.TNonblockingServerTransport;
@@ -225,13 +226,14 @@ public class HRegionThriftServer extends
           transportFactory = new TTransportFactory();
         }
 
-        TThreadPoolServer.Args serverArgs = new TThreadPoolServer.Args(serverTransport);
+        TBoundedThreadPoolServer.Args serverArgs =
+            new TBoundedThreadPoolServer.Args(serverTransport, conf);
         serverArgs.processor(processor);
         serverArgs.protocolFactory(protocolFactory);
         serverArgs.transportFactory(transportFactory);
         LOG.info("starting HRegionServer ThreadPool Thrift server on " +
                  listenAddress + ":" + this.port);
-        tserver = new TThreadPoolServer(serverArgs);
+        tserver = new TBoundedThreadPoolServer(serverArgs);
       }
       tserver.serve();
     } catch (Exception e) {



Mime
View raw message