Package io.hekate.election
Interface LeaderChangeListener
-
public interface LeaderChangeListener
Listener of leader change events.Implementations of this interface can be registered by a
Candidate
to itsFollowerContext
in order to get leader change notifications while candidate stays in thefollower
state.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
onLeaderChange(FollowerContext ctx)
Called every time when some other node wins elections and takes a group leadership.
-
-
-
Method Detail
-
onLeaderChange
void onLeaderChange(FollowerContext ctx)
Called every time when some other node wins elections and takes a group leadership.- Parameters:
ctx
- Follower context.
-
-