0

In the Leader Election feature of the Apache Curator framework, is it possible to "prefer" a leader for a given latch group, so that if it's online, it takes precedence (leadership) over the others (that would lose leadership when the "preferred" one comes online)?

I am using a Zookeeper quorum of 3 nodes, and having an application using the leader election pattern on 2 instances (primary, secondary).
When the primary goes down, the secondary successfully acquires leadership and resumes the work.
When the primary comes back, the secondary instance remains the leader. Is it possible somehow to configure it so that the primary instance "steals" leadership from the secondary?

Thomas
  • 1,053
  • 2
  • 11
  • 20

0 Answers0