hbase -regions assignment(in creating table)

本文深入探讨了HBase中Region分配机制及其与Zookeeper的交互过程,详细阐述了Zookeeper相关事件的处理流程和触发机制,包括节点创建、删除、数据改变和子节点变化等事件,并解释了当同时使用'exists'和'data'注册时,更新节点时触发顺序的规则。

as iwinit dug in source codes[1],the 'regions assigment' in hbase is complex and trickle.there are many of zk related events across master and rs,and huge of pre-post processes in it.

below is a abstract view i figured out:

 

 

 against zookeeper,u will find the many of interesting processing models like these:

a.A creates znodes in zk with raw state;

b.B does some processes that it should expect;then update the state ;

c.A receives that events,then finalize the znode and post-business

 

last,i wonder to declare that some important zk related events across this assignment:

 

 

 

 also,below is the zookeeper events trigger basics:



 that means there is a 3-d trigger model:

Enumeration of types of events that may occur on the ZooKeeper
EventType tirgger creation point(register)trigger event(operation)usage

NodeCreated

existscreate a znode 

NodeDeleted

exists,getData,

getChildren(this is the case of deletion of parent znode)

delete a znode 

NodeDataChanged

exists,getDataupdate/set a znode with new/old data 

NodeChildrenChanged

getChildrencreate/delete a child znode  

 

in other words,by simplely,u can:

 

make a 'trigger operation' -> then through previously 'register' -> then get a appropriate callback 'EventType'
 

 

but one thing i have no idea is which register will be triggered first when updating a znode if i use both 'exists' and 'getData' register on the same znode?

i this there will be some rules to do this in zk.so i will check for the source also soon later ...TODO

 

 

ref:

[1] [HBase]Region assignment

hadoop-guide

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值