As of MySQL 5.7.3, the Performance Schema exposes table lock
information through the
table_handles table to show the
table locks currently in effect for each opened table handle.
table_handles reports what is
recorded by the table lock instrumentation. This information
shows which table handles the server has open, how they are
locked, and by which sessions.
table_handles table has these
The table opened by a table handle.
The schema that contains the object.
The name of the instrumented object.
The table handle address in memory.
The thread owning the table handle.
The event which caused the table handle to be opened.
The table lock used at the SQL level. The value is one of
READ WITH SHARED
READ HIGH PRIORITY,
READ NO INSERT,
WRITE LOW PRIORITY,
WRITE. For information about these
lock types, see the
include/thr_lock.h source file.
The table lock used at the storage engine level. The value
is one of
READ EXTERNAL or