读书人

Hbase 源码分析四 - Get 流程及rpc原理

发布时间: 2012-08-10 12:19:33 作者: rapoo

Hbase 源码分析4 - Get 流程及rpc原理

分析版本为hbase 0.94

附上趋势团队画的图:

Hbase 源码分析四 - Get 流程及rpc原理

rpc角色表:

HBase通信信道HBase的通信接口this.service = new ExecutorService(getServerName().toString());this.service.startExecutorService(ExecutorType.RS_OPEN_REGION,conf.getInt("hbase.regionserver.executor.openregion.threads", 3));this.service.startExecutorService(ExecutorType.RS_OPEN_ROOT,conf.getInt("hbase.regionserver.executor.openroot.threads", 1));this.service.startExecutorService(ExecutorType.RS_OPEN_META,conf.getInt("hbase.regionserver.executor.openmeta.threads", 1));this.service.startExecutorService(ExecutorType.RS_CLOSE_REGION,conf.getInt("hbase.regionserver.executor.closeregion.threads", 3));this.service.startExecutorService(ExecutorType.RS_CLOSE_ROOT,conf.getInt("hbase.regionserver.executor.closeroot.threads", 1));this.service.startExecutorService(ExecutorType.RS_CLOSE_META,conf.getInt("hbase.regionserver.executor.closemeta.threads", 1));

hlogRoller(daemon)

cacheFlusher(daemon)

compactionChecker(daemon)

Leases(它不是线程,会启动后台线程)

splitLogWorker

rpcServer

HBaseClient 和 HMaster关系由HMasterInterface描述:

Clients interact with the HMasterInterface to gain access to meta-level
HBase functionality, like finding an HRegionServer and creating/destroying
tables.

HBaseClient 和 HRegionServer关系由HRegionInterface描述:

Clients interact with HRegionServers using a handle to the HRegionInterface

参考资料:

http://zjushch.iteye.com/blog/1173304

http://www.spnguru.com/2010/07/hbase-%E6%BA%90%E7%A0%81%E5%88%86%E6%9E%90-rpc%E6%9C%BA%E5%88%B6-%E5%9F%BA%E7%A1%80/

读书人网 >其他数据库

热点推荐