MySQL 9.1.0
Source Code Documentation
Innodb_data_lock_wait_iterator Class Reference

Inspect data lock waits for the innodb storage engine. More...

Inheritance diagram for Innodb_data_lock_wait_iterator:
[legend]

Public Member Functions

bool scan (PSI_server_data_lock_wait_container *container) override
 Scan for more data lock waits. More...
 
void fetch (PSI_server_data_lock_wait_container *container, const char *requesting_engine_lock_id, size_t requesting_engine_lock_id_length, const char *blocking_engine_lock_id, size_t blocking_engine_lock_id_length) override
 Fetch a given data lock wait. More...
 
- Public Member Functions inherited from PSI_engine_data_lock_wait_iterator
 PSI_engine_data_lock_wait_iterator ()=default
 
virtual ~PSI_engine_data_lock_wait_iterator ()=default
 

Static Private Member Functions

static size_t report (PSI_server_data_lock_wait_container &container, const lock_t &wait_lock, bool with_filter, const lock_guid_t &filter_blocking_lock_guid=lock_guid_t())
 For a given wait_lock it will inform container about each lock which is blocking this wait_lock, subject to filtering defined for the container, and optionally by filter_blocking_lock_immutable_id if with_filter is true. More...
 

Private Attributes

All_locks_iterator m_all_locks_iterator
 

Detailed Description

Inspect data lock waits for the innodb storage engine.

Member Function Documentation

◆ fetch()

void Innodb_data_lock_wait_iterator::fetch ( PSI_server_data_lock_wait_container container,
const char *  requesting_engine_lock_id,
size_t  requesting_engine_lock_id_length,
const char *  blocking_engine_lock_id,
size_t  blocking_engine_lock_id_length 
)
overridevirtual

Fetch a given data lock wait.

Parameters
containerThe container to fill
requesting_engine_lock_idThe requesting lock id to search
requesting_engine_lock_id_lengthThe requesting lock id length
blocking_engine_lock_idThe blocking lock id to search
blocking_engine_lock_id_lengthThe blocking lock id length

Implements PSI_engine_data_lock_wait_iterator.

◆ report()

size_t Innodb_data_lock_wait_iterator::report ( PSI_server_data_lock_wait_container container,
const lock_t wait_lock,
bool  with_filter,
const lock_guid_t filter_blocking_lock_guid = lock_guid_t() 
)
staticprivate

For a given wait_lock it will inform container about each lock which is blocking this wait_lock, subject to filtering defined for the container, and optionally by filter_blocking_lock_immutable_id if with_filter is true.

The with_filter is used to fetch just a single blocking lock, the one specified by its immutable id. Please note, that there is no guarantee that this blocking lock is still in the lock sys.

Parameters
[in,out]containerThe container to fill. Serves as both visitor and filter
[in]wait_lockThe requesting lock which has to wait
[in]with_filterIf true then filter_blocking_lock_immutable_id has to be passed, and means that only the lock with that immutable id (if still present and matches the container's filters) should be reported to the container. If false then all locks blocking the wait_lock are considered for reporting.
[in]filter_blocking_lock_guidif with_filter is true it further narrows the set of reported locks to just the one with given guid.
Returns
number of locks reported to the container

◆ scan()

bool Innodb_data_lock_wait_iterator::scan ( PSI_server_data_lock_wait_container container)
overridevirtual

Scan for more data lock waits.

Parameters
containerThe container to fill
Returns
true if the iterator is done

Implements PSI_engine_data_lock_wait_iterator.

Member Data Documentation

◆ m_all_locks_iterator

All_locks_iterator Innodb_data_lock_wait_iterator::m_all_locks_iterator
private

The documentation for this class was generated from the following file: