zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From john doe <john.doe44...@gmail.com>
Subject curator leader election and thread usage
Date Mon, 07 May 2012 12:13:38 GMT

I am currently using curator to manage leader election (which I find really
nice btw), and I have a question:

I am using leaders to manage shards of a database. When a node (=a jvm) is
started, it is told what shards it could manage if it is elected for this
shard. A node can be elected for multiple shards.

The issue I got is that a node typically manages hundreds of shards. Not
sure I understood correctly, but current leader election receipe (as
implemented in curator) results in the creation of hundreds of threads,
which I keep sleeping because actual processing is done by a separate
thread pool.

Is there a way not to use that many threads, given that when a node is
elected for a shard it will never release its leadership?



  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message