Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Zookeeper >> mail # dev >> How does leader/follower invoke setupRequestProcessors()?

Copy link to this message
Re: How does leader/follower invoke setupRequestProcessors()?
You can follow the code to see that the startup() method (in
ZooKeeperServer()) is the one that leads to all the setup methods
being called. Take a look at ServerCnxnFactory.start() and you should
be able to follow how its being called.

OTOH, the start up code isnt very clean right now. It needs a little
bit of cleanup to make it more understandable.

hope that helps

2011/8/31 朱君 <[EMAIL PROTECTED]>:
> HI,
> I am reading the source code of ZooKeeper 3.3.0, and stucked.
> After the instance of LeaderZooKeeperServer (inherit from QuorumZooKeeperServer which inherits from ZooKeeperServer ) has been created (in class QuorumPeer:657), where does it invoke setupRequestProcessors()? In standalone mode, it is easy to find whre setupRequestProcessors is called. But in quorum mode, i don't know how the function is invoked.
> Thanks very much!
> 2011-08-31
> Jun