Module tikv::server::lock_manager::deadlock[][src]

Structs

DetectTable

Used to detect the deadlock of wait-for-lock in the cluster.

Detector

Detector is used to detect deadlocks between transactions. There is a leader in the cluster which collects all wait_for_entry from other followers.

Inner
Locks

Locks is a set of locks belonging to one transaction.

RoleChangeNotifier

RoleChangeNotifier observes region or role change events of raftstore. If the region is the leader region and the role of this node is changed, a ChangeRole task will be scheduled to the deadlock detector. It’s the only way to change the node from the leader of deadlock detector to follower, and vice versa.

Scheduler

Scheduler is the wrapper of the FutureScheduler<Task> to simplify scheduling tasks to the deadlock detector.

Service

Enums

DetectType
Role

The role of the detector.

Task

Constants

LEADER_KEY

The leader region is the region containing the LEADER_KEY and the leader of the leader region is also the leader of the deadlock detector.