MySQL 8.0.40
Source Code Documentation
|
The lock system struct. More...
#include <lock0lock.h>
Public Member Functions | |
lock_sys_t (size_t n_cells) | |
Public Attributes | |
locksys::Latches | latches |
The latches protecting queues of record and table locks. More... | |
Locks_hashtable | rec_hash |
The hash table of the record (LOCK_REC) locks, except for predicate (LOCK_PREDICATE) and predicate page (LOCK_PRDT_PAGE) locks. More... | |
Locks_hashtable | prdt_hash |
The hash table of predicate (LOCK_PREDICATE) locks. More... | |
Locks_hashtable | prdt_page_hash |
The hash table of the predicate page (LOCK_PRD_PAGE) locks. More... | |
uint32_t | n_resizes |
number of calls to lock_sys_resize() so far. More... | |
char | pad2 [ut::INNODB_CACHE_LINE_SIZE] |
Padding to avoid false sharing of wait_mutex field. More... | |
Lock_mutex | wait_mutex |
The mutex protecting the next two fields. More... | |
srv_slot_t * | waiting_threads |
Array of user threads suspended while waiting for locks within InnoDB. More... | |
srv_slot_t * | last_slot |
The highest slot ever used in the waiting_threads array. More... | |
bool | rollback_complete |
true if rollback of all recovered transactions is complete. More... | |
std::chrono::steady_clock::duration | n_lock_max_wait_time |
Max lock wait time observed, for innodb_row_lock_time_max reporting. More... | |
os_event_t | timeout_event |
Set to the event that is created in the lock wait monitor thread. More... | |
std::atomic< uint64_t > | m_seq |
Lock timestamp counter, used to assign lock->m_seq on creation. More... | |
The lock system struct.
|
inline |
srv_slot_t* lock_sys_t::last_slot |
The highest slot ever used in the waiting_threads array.
Protected by lock_sys->wait_mutex.
locksys::Latches lock_sys_t::latches |
The latches protecting queues of record and table locks.
std::atomic<uint64_t> lock_sys_t::m_seq |
Lock timestamp counter, used to assign lock->m_seq on creation.
std::chrono::steady_clock::duration lock_sys_t::n_lock_max_wait_time |
Max lock wait time observed, for innodb_row_lock_time_max reporting.
uint32_t lock_sys_t::n_resizes |
number of calls to lock_sys_resize() so far.
Used to determine if iterators should be invalidated. Modified under global exclusive lock_sys latch. Read under global shared lock_sys latch.
char lock_sys_t::pad2[ut::INNODB_CACHE_LINE_SIZE] |
Padding to avoid false sharing of wait_mutex field.
Locks_hashtable lock_sys_t::prdt_hash |
The hash table of predicate (LOCK_PREDICATE) locks.
Locks_hashtable lock_sys_t::prdt_page_hash |
The hash table of the predicate page (LOCK_PRD_PAGE) locks.
Locks_hashtable lock_sys_t::rec_hash |
The hash table of the record (LOCK_REC) locks, except for predicate (LOCK_PREDICATE) and predicate page (LOCK_PRDT_PAGE) locks.
bool lock_sys_t::rollback_complete |
true if rollback of all recovered transactions is complete.
Protected by exclusive global lock_sys latch.
os_event_t lock_sys_t::timeout_event |
Set to the event that is created in the lock wait monitor thread.
A value of 0 means the thread is not active
Lock_mutex lock_sys_t::wait_mutex |
The mutex protecting the next two fields.
srv_slot_t* lock_sys_t::waiting_threads |
Array of user threads suspended while waiting for locks within InnoDB.
Protected by the lock_sys->wait_mutex.