Skip to content

kv: gossip leaseholder changes as they occur #50199

@knz

Description

@knz

Today, if a node transfers its leases away, any other node that is neither the old nor new holder of the lease but has a cached record of that lease, will first attempt to contact the old leaseholder before it "discovers" that the lease is somewhere else.

If the old leaseholder is down at that time (as would be expected if it was e.g. stopped or restarted), a brief period of unavailability ensures until the requesting node looks up an update LH record.

We want to avoid this unavailability by preemptively noticing all nodes in the cluster of LH changes, so they can invalidate their caches.

@andreimatei suggests to do this via gossip.

Jira issue: CRDB-4143

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-kv-replicationRelating to Raft, consensus, and coordination.C-enhancementSolution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)T-kvKV Team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions