Skip to content

_leader_lease should also be considered when handling vote #463

@BusyJay

Description

@BusyJay

Currently only _follower_lease is considered, and leader will never update _follower_lease, so _follower_lease will always expire on leader side. If a follower starts election in an idle group, leader will vote for follower even the leader lease is still valid. Leader will call step_down to invalidate _leader_lease before vote, so there seems to be no correctness problem. But if a follower is isolated for a while and then return, it's likely to cause leadership change and lead to latency jitter on the client side.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions