MySQL  8.0.17
Source Code Documentation

Classes

class  Proc_purge_account
 
class  Proc_update_accounts_derived_flags
 
struct  PFS_account_key
 Hash key for an account. More...
 
struct  PFS_account
 Per account statistics. More...
 
struct  PFS_connection_slice
 A connection slice, an arbitrary grouping of several connections. More...
 
class  Proc_purge_host
 
struct  PFS_host_key
 Hash key for a host. More...
 
struct  PFS_host
 Per host statistics. More...
 
struct  PFS_instr
 Base structure for wait instruments. More...
 
struct  PFS_mutex
 Instrumented mutex implementation. More...
 
struct  PFS_rwlock
 Instrumented rwlock implementation. More...
 
struct  PFS_cond
 Instrumented condition implementation. More...
 
struct  PFS_file
 Instrumented File and FILE implementation. More...
 
struct  PFS_table
 Instrumented table implementation. More...
 
struct  PFS_socket
 Instrumented socket implementation. More...
 
struct  PFS_metadata_lock
 Instrumented metadata lock implementation. More...
 
struct  PFS_thread
 Instrumented thread implementation. More...
 
class  Proc_table_share_derived_flags
 
class  Proc_program_share_derived_flags
 
struct  PFS_instr_config
 User-defined instrument configuration. More...
 
struct  PFS_instr_class
 Information for all instrumentation. More...
 
struct  PFS_mutex_class
 Instrumentation metadata for a mutex. More...
 
struct  PFS_rwlock_class
 Instrumentation metadata for a read write lock. More...
 
struct  PFS_cond_class
 Instrumentation metadata for a condition. More...
 
struct  PFS_thread_class
 Instrumentation metadata of a thread. More...
 
struct  PFS_table_share_key
 Key identifying a table share. More...
 
struct  PFS_table_key
 Table index or 'key'. More...
 
struct  PFS_table_share_index
 Index statistics of a table. More...
 
struct  PFS_table_share_lock
 Lock statistics of a table. More...
 
struct  PFS_table_share
 Instrumentation metadata for a table share. More...
 
struct  PFS_error_class
 Instrumentation metadata for an error. More...
 
struct  PFS_file_class
 Instrumentation metadata for a file. More...
 
struct  PFS_stage_class
 Instrumentation metadata for a stage. More...
 
struct  PFS_statement_class
 Instrumentation metadata for a statement. More...
 
struct  PFS_transaction_class
 Instrumentation metadata for a transaction. More...
 
struct  PFS_socket_class
 Instrumentation metadata for a socket. More...
 
struct  PFS_memory_class
 Instrumentation metadata for a memory. More...
 
struct  pfs_optimistic_state
 
struct  pfs_dirty_state
 
struct  pfs_lock
 A 'lock' protecting performance schema internal buffers. More...
 
class  Proc_reset_setup_actor
 
struct  PFS_setup_actor_key
 Hash key for. More...
 
struct  PFS_setup_actor
 A setup_actor record. More...
 
class  Proc_reset_setup_object
 
struct  PFS_setup_object_key
 Hash key for. More...
 
struct  PFS_setup_object
 A setup_object record. More...
 
struct  PFS_single_stat
 Single statistic. More...
 
struct  PFS_byte_stat
 Combined statistic. More...
 
struct  PFS_mutex_stat
 Statistics for mutex usage. More...
 
struct  PFS_rwlock_stat
 Statistics for rwlock usage. More...
 
struct  PFS_cond_stat
 Statistics for conditions usage. More...
 
struct  PFS_file_io_stat
 Statistics for FILE I/O. More...
 
struct  PFS_file_stat
 Statistics for FILE usage. More...
 
struct  PFS_stage_stat
 Statistics for stage usage. More...
 
struct  PFS_sp_stat
 Statistics for stored program usage. More...
 
struct  PFS_prepared_stmt_stat
 Statistics for prepared statement usage. More...
 
struct  PFS_statement_stat
 Statistics for statement usage. More...
 
struct  PFS_transaction_stat
 Statistics for transaction usage. More...
 
struct  PFS_error_single_stat
 Statistics for a server error. More...
 
struct  PFS_error_stat
 
struct  PFS_table_io_stat
 Single table I/O statistic. More...
 
struct  PFS_table_lock_stat
 Statistics for table locks. More...
 
struct  PFS_table_stat
 Statistics for TABLE usage. More...
 
struct  PFS_socket_io_stat
 Statistics for SOCKET I/O. More...
 
struct  PFS_socket_stat
 Statistics for SOCKET usage. More...
 
struct  PFS_memory_stat_delta
 
struct  PFS_memory_shared_stat
 
struct  PFS_memory_safe_stat
 Memory statistics. More...
 
struct  PFS_connection_stat
 Connections statistics. More...
 
class  Proc_purge_user
 
struct  PFS_user_key
 Hash key for a user. More...
 
struct  PFS_user
 Per user statistics. More...
 
class  All_THD_visitor_adapter
 
class  All_host_THD_visitor_adapter
 
class  All_user_THD_visitor_adapter
 
class  All_account_THD_visitor_adapter
 
class  Proc_all_table_shares
 
class  Proc_all_table_handles
 
class  Proc_one_table_share_handles
 
class  Proc_one_table_share_indexes
 
class  PFS_connection_visitor
 Interface class to visit groups of connections. More...
 
class  PFS_connection_iterator
 Iterator over groups of connections. More...
 
class  PFS_instance_visitor
 Interface class to visit groups of instrumentation point instances. More...
 
class  PFS_instance_iterator
 Iterator over groups of instrumentation point instances. More...
 
class  PFS_object_visitor
 Interface class to visit groups of SQL objects. More...
 
class  PFS_object_iterator
 Iterator over groups of SQL objects. More...
 
class  PFS_connection_wait_visitor
 A concrete connection visitor that aggregates wait statistics for a given event_name. More...
 
class  PFS_connection_all_wait_visitor
 A concrete connection visitor that aggregates wait statistics for all events. More...
 
class  PFS_connection_stage_visitor
 A concrete connection visitor that aggregates stage statistics. More...
 
class  PFS_connection_statement_visitor
 A concrete connection visitor that aggregates statement statistics for a given event_name. More...
 
class  PFS_connection_all_statement_visitor
 A concrete connection visitor that aggregates statement statistics for all events. More...
 
class  PFS_connection_transaction_visitor
 A concrete connection visitor that aggregates transaction statistics for a given event_name. More...
 
class  PFS_connection_error_visitor
 A concrete connection visitor that aggregates Error statistics for a given event_name. More...
 
class  PFS_connection_stat_visitor
 A concrete connection visitor that aggregates connection statistics. More...
 
class  PFS_connection_memory_visitor
 A concrete connection visitor that aggregates memory statistics for a given event_name. More...
 
class  PFS_connection_status_visitor
 A concrete connection visitor that aggregates status variables. More...
 
class  PFS_instance_wait_visitor
 A concrete instance visitor that aggregates wait statistics. More...
 
class  PFS_object_wait_visitor
 A concrete object visitor that aggregates object wait statistics. More...
 
class  PFS_table_io_wait_visitor
 A concrete object visitor that aggregates table I/O wait statistics. More...
 
class  PFS_table_io_stat_visitor
 A concrete object visitor that aggregates table I/O statistics. More...
 
class  PFS_index_io_stat_visitor
 A concrete object visitor that aggregates index I/O statistics. More...
 
class  PFS_table_lock_wait_visitor
 A concrete object visitor that aggregates table lock wait statistics. More...
 
class  PFS_table_lock_stat_visitor
 A concrete object visitor that aggregates table lock statistics. More...
 
class  PFS_instance_socket_io_stat_visitor
 A concrete instance visitor that aggregates socket wait and byte count statistics. More...
 
class  PFS_instance_file_io_stat_visitor
 A concrete instance visitor that aggregates file wait and byte count statistics. More...
 

Macros

#define WAIT_STACK_LOGICAL_SIZE   5
 Maximum number of nested waits. More...
 
#define WAIT_STACK_BOTTOM   1
 Maximum number dummy waits records. More...
 
#define WAIT_STACK_SIZE   (WAIT_STACK_BOTTOM + WAIT_STACK_LOGICAL_SIZE)
 Physical size of the waits stack. More...
 
#define REGISTER_CLASS_BODY_PART(INDEX, ARRAY, MAX, NAME, NAME_LENGTH)
 
#define FIND_CLASS_BODY(KEY, COUNT, ARRAY)
 
#define PFS_MUTEX_PARTITIONS   2
 
#define GLOBAL_TABLE_IO_EVENT_INDEX   0
 
#define GLOBAL_TABLE_LOCK_EVENT_INDEX   1
 
#define GLOBAL_IDLE_EVENT_INDEX   2
 
#define GLOBAL_METADATA_EVENT_INDEX   3
 
#define COUNT_GLOBAL_EVENT_INDEX   4
 Number of global wait events. More...
 
#define GLOBAL_TRANSACTION_INDEX   0
 Transaction events are not wait events . More...
 
#define GLOBAL_ERROR_INDEX   0
 
#define PFS_LOCK_FREE   0x00
 State of a free record. More...
 
#define PFS_LOCK_DIRTY   0x01
 State of a dirty record. More...
 
#define PFS_LOCK_ALLOCATED   0x02
 State of an allocated record. More...
 
#define VERSION_MASK   0xFFFFFFFC
 
#define STATE_MASK   0x00000003
 
#define VERSION_INC   4
 
#define COUNT_PFS_TL_LOCK_TYPE   10
 
#define PFS_MEMORY_STAT_INITIALIZER   { false, 0, 0, 0, 0, 0, 0, 0, 0 }
 

Typedefs

typedef unsigned int PFS_sync_key
 Key, naming a synch instrument (mutex, rwlock, cond). More...
 
typedef unsigned int PFS_thread_key
 Key, naming a thread instrument. More...
 
typedef unsigned int PFS_file_key
 Key, naming a file instrument. More...
 
typedef unsigned int PFS_stage_key
 Key, naming a stage instrument. More...
 
typedef unsigned int PFS_statement_key
 Key, naming a statement instrument. More...
 
typedef unsigned int PFS_transaction_key
 Key, naming a transaction instrument. More...
 
typedef unsigned int PFS_socket_key
 Key, naming a socket instrument. More...
 
typedef unsigned int PFS_memory_key
 Key, naming a memory instrument. More...
 
typedef Prealloced_array< PFS_instr_config *, 10 > Pfs_instr_config_array
 

Enumerations

enum  PFS_class_type {
  PFS_CLASS_NONE = 0, PFS_CLASS_MUTEX = 1, PFS_CLASS_RWLOCK = 2, PFS_CLASS_COND = 3,
  PFS_CLASS_FILE = 4, PFS_CLASS_TABLE = 5, PFS_CLASS_STAGE = 6, PFS_CLASS_STATEMENT = 7,
  PFS_CLASS_TRANSACTION = 8, PFS_CLASS_SOCKET = 9, PFS_CLASS_TABLE_IO = 10, PFS_CLASS_TABLE_LOCK = 11,
  PFS_CLASS_IDLE = 12, PFS_CLASS_MEMORY = 13, PFS_CLASS_METADATA = 14, PFS_CLASS_ERROR = 15,
  PFS_CLASS_THREAD = 16, PFS_CLASS_LAST = PFS_CLASS_THREAD, PFS_CLASS_MAX = PFS_CLASS_LAST + 1
}
 
enum  PFS_TL_LOCK_TYPE {
  PFS_TL_READ = 0, PFS_TL_READ_WITH_SHARED_LOCKS = 1, PFS_TL_READ_HIGH_PRIORITY = 2, PFS_TL_READ_NO_INSERT = 3,
  PFS_TL_WRITE_ALLOW_WRITE = 4, PFS_TL_WRITE_CONCURRENT_INSERT = 5, PFS_TL_WRITE_LOW_PRIORITY = 6, PFS_TL_WRITE = 7,
  PFS_TL_READ_EXTERNAL = 8, PFS_TL_WRITE_EXTERNAL = 9, PFS_TL_NONE = 99
}
 

Functions

int init_account (const PFS_global_param *param)
 Initialize the user buffers. More...
 
void cleanup_account (void)
 Cleanup all the account buffers. More...
 
static const ucharaccount_hash_get_key (const uchar *entry, size_t *length)
 
int init_account_hash (const PFS_global_param *param)
 Initialize the user hash. More...
 
void cleanup_account_hash (void)
 Cleanup the user hash. More...
 
static LF_PINSget_account_hash_pins (PFS_thread *thread)
 
static void set_account_key (PFS_account_key *key, const char *user, uint user_length, const char *host, uint host_length)
 
PFS_accountfind_or_create_account (PFS_thread *thread, const char *username, uint username_length, const char *hostname, uint hostname_length)
 
PFS_accountsanitize_account (PFS_account *unsafe)
 
static void purge_account (PFS_thread *thread, PFS_account *account)
 
void purge_all_account (void)
 Purge non connected accounts, reset stats of connected account. More...
 
void update_accounts_derived_flags (PFS_thread *thread)
 
int init_host (const PFS_global_param *param)
 Initialize the host buffers. More...
 
void cleanup_host (void)
 Cleanup all the host buffers. More...
 
static const ucharhost_hash_get_key (const uchar *entry, size_t *length)
 
int init_host_hash (const PFS_global_param *param)
 Initialize the host hash. More...
 
void cleanup_host_hash (void)
 Cleanup the host hash. More...
 
static LF_PINSget_host_hash_pins (PFS_thread *thread)
 
static void set_host_key (PFS_host_key *key, const char *host, uint host_length)
 
PFS_hostfind_or_create_host (PFS_thread *thread, const char *hostname, uint hostname_length)
 
PFS_hostsanitize_host (PFS_host *unsafe)
 
static void purge_host (PFS_thread *thread, PFS_host *host)
 
void purge_all_host (void)
 Purge non connected hosts, reset stats of connected hosts. More...
 
int init_instruments (const PFS_global_param *param)
 Initialize all the instruments instance buffers. More...
 
void cleanup_instruments (void)
 Cleanup all the instruments buffers. More...
 
static const ucharfilename_hash_get_key (const uchar *entry, size_t *length)
 Get hash table key for instrumented files. More...
 
int init_file_hash (const PFS_global_param *param)
 Initialize the file name hash. More...
 
void cleanup_file_hash (void)
 Cleanup the file name hash. More...
 
PFS_mutexcreate_mutex (PFS_mutex_class *klass, const void *identity)
 Create instrumentation for a mutex instance. More...
 
void destroy_mutex (PFS_mutex *pfs)
 Destroy instrumentation for a mutex instance. More...
 
PFS_rwlockcreate_rwlock (PFS_rwlock_class *klass, const void *identity)
 Create instrumentation for a rwlock instance. More...
 
void destroy_rwlock (PFS_rwlock *pfs)
 Destroy instrumentation for a rwlock instance. More...
 
PFS_condcreate_cond (PFS_cond_class *klass, const void *identity)
 Create instrumentation for a condition instance. More...
 
void destroy_cond (PFS_cond *pfs)
 Destroy instrumentation for a condition instance. More...
 
void carry_global_memory_stat_delta (PFS_memory_stat_delta *delta, uint index)
 
PFS_threadcreate_thread (PFS_thread_class *klass, const void *identity, ulonglong processlist_id)
 Create instrumentation for a thread instance. More...
 
PFS_threadfind_thread_by_internal_id (ulonglong thread_id)
 Find a PFS thread given an internal thread id. More...
 
PFS_threadfind_thread_by_processlist_id (ulonglong processlist_id)
 Find a PFS thread given a processlist id. More...
 
PFS_mutexsanitize_mutex (PFS_mutex *unsafe)
 
PFS_rwlocksanitize_rwlock (PFS_rwlock *unsafe)
 
PFS_condsanitize_cond (PFS_cond *unsafe)
 
PFS_threadsanitize_thread (PFS_thread *unsafe)
 Sanitize a PFS_thread pointer. More...
 
PFS_filesanitize_file (PFS_file *unsafe)
 
PFS_socketsanitize_socket (PFS_socket *unsafe)
 
PFS_metadata_locksanitize_metadata_lock (PFS_metadata_lock *unsafe)
 
void destroy_thread (PFS_thread *pfs)
 Destroy instrumentation for a thread instance. More...
 
static LF_PINSget_filename_hash_pins (PFS_thread *thread)
 Get the hash pins for filename_hash. More...
 
PFS_filefind_or_create_file (PFS_thread *thread, PFS_file_class *klass, const char *filename, uint len, bool create)
 Find or create instrumentation for a file instance by file name. More...
 
void find_and_rename_file (PFS_thread *thread, const char *old_filename, uint old_len, const char *new_filename, uint new_len)
 Find a file instrumentation instance by name, and rename it. More...
 
void release_file (PFS_file *pfs)
 Release instrumentation for a file instance. More...
 
void destroy_file (PFS_thread *thread, PFS_file *pfs)
 Destroy instrumentation for a file instance. More...
 
PFS_tablecreate_table (PFS_table_share *share, PFS_thread *opening_thread, const void *identity)
 Create instrumentation for a table instance. More...
 
void destroy_table (PFS_table *pfs)
 Destroy instrumentation for a table instance. More...
 
PFS_socketcreate_socket (PFS_socket_class *klass, const my_socket *fd, const struct sockaddr *addr, socklen_t addr_len)
 Create instrumentation for a socket instance. More...
 
void destroy_socket (PFS_socket *pfs)
 Destroy instrumentation for a socket instance. More...
 
PFS_metadata_lockcreate_metadata_lock (void *identity, const MDL_key *mdl_key, opaque_mdl_type mdl_type, opaque_mdl_duration mdl_duration, opaque_mdl_status mdl_status, const char *src_file, uint src_line)
 
void destroy_metadata_lock (PFS_metadata_lock *pfs)
 
static void fct_reset_mutex_waits (PFS_mutex *pfs)
 
static void reset_mutex_waits_by_instance (void)
 
static void fct_reset_rwlock_waits (PFS_rwlock *pfs)
 
static void reset_rwlock_waits_by_instance (void)
 
static void fct_reset_cond_waits (PFS_cond *pfs)
 
static void reset_cond_waits_by_instance (void)
 
static void fct_reset_file_waits (PFS_file *pfs)
 
static void reset_file_waits_by_instance (void)
 
static void fct_reset_socket_waits (PFS_socket *pfs)
 
static void reset_socket_waits_by_instance (void)
 
void reset_events_waits_by_instance (void)
 Reset the wait statistics per object instance. More...
 
static void fct_reset_file_io (PFS_file *pfs)
 
void reset_file_instance_io (void)
 Reset the I/O statistics per file instance. More...
 
static void fct_reset_socket_io (PFS_socket *pfs)
 
void reset_socket_instance_io (void)
 Reset the I/O statistics per socket instance. More...
 
void reset_histogram_global ()
 
void aggregate_all_event_names (PFS_single_stat *from_array, PFS_single_stat *to_array)
 
void aggregate_all_event_names (PFS_single_stat *from_array, PFS_single_stat *to_array_1, PFS_single_stat *to_array_2)
 
void aggregate_all_stages (PFS_stage_stat *from_array, PFS_stage_stat *to_array)
 
void aggregate_all_stages (PFS_stage_stat *from_array, PFS_stage_stat *to_array_1, PFS_stage_stat *to_array_2)
 
void aggregate_all_statements (PFS_statement_stat *from_array, PFS_statement_stat *to_array)
 
void aggregate_all_statements (PFS_statement_stat *from_array, PFS_statement_stat *to_array_1, PFS_statement_stat *to_array_2)
 
void aggregate_all_transactions (PFS_transaction_stat *from_array, PFS_transaction_stat *to_array)
 
void aggregate_all_transactions (PFS_transaction_stat *from_array, PFS_transaction_stat *to_array_1, PFS_transaction_stat *to_array_2)
 
void aggregate_all_errors (PFS_error_stat *from_array, PFS_error_stat *to_array)
 
void aggregate_all_errors (PFS_error_stat *from_array, PFS_error_stat *to_array_1, PFS_error_stat *to_array_2)
 
void aggregate_all_memory (bool alive, PFS_memory_safe_stat *from_array, PFS_memory_shared_stat *to_array)
 
void aggregate_all_memory (bool alive, PFS_memory_shared_stat *from_array, PFS_memory_shared_stat *to_array)
 
void aggregate_all_memory (bool alive, PFS_memory_safe_stat *from_array, PFS_memory_shared_stat *to_array_1, PFS_memory_shared_stat *to_array_2)
 
void aggregate_all_memory (bool alive, PFS_memory_shared_stat *from_array, PFS_memory_shared_stat *to_array_1, PFS_memory_shared_stat *to_array_2)
 
void aggregate_thread_status (PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
static void aggregate_thread_stats (PFS_thread *, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void aggregate_thread (PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void aggregate_thread_waits (PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void aggregate_thread_stages (PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void aggregate_thread_statements (PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void aggregate_thread_transactions (PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void aggregate_thread_errors (PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void aggregate_thread_memory (bool alive, PFS_thread *thread, PFS_account *safe_account, PFS_user *safe_user, PFS_host *safe_host)
 
void clear_thread_account (PFS_thread *thread)
 
void set_thread_account (PFS_thread *thread)
 
static void fct_update_mutex_derived_flags (PFS_mutex *pfs)
 
void update_mutex_derived_flags ()
 Update derived flags for all mutex instances. More...
 
static void fct_update_rwlock_derived_flags (PFS_rwlock *pfs)
 
void update_rwlock_derived_flags ()
 Update derived flags for all rwlock instances. More...
 
static void fct_update_cond_derived_flags (PFS_cond *pfs)
 
void update_cond_derived_flags ()
 Update derived flags for all condition instances. More...
 
static void fct_update_file_derived_flags (PFS_file *pfs)
 
void update_file_derived_flags ()
 Update derived flags for all file handles. More...
 
static void fct_update_table_derived_flags (PFS_table *pfs)
 
void update_table_derived_flags ()
 Update derived flags for all table handles. More...
 
static void fct_update_socket_derived_flags (PFS_socket *pfs)
 
void update_socket_derived_flags ()
 Update derived flags for all socket instances. More...
 
static void fct_reset_metadata_source_file_pointers (PFS_metadata_lock *pfs)
 
static void fct_update_metadata_derived_flags (PFS_metadata_lock *pfs)
 
void update_metadata_derived_flags ()
 Update derived flags for all metadata instances. More...
 
static void fct_update_thread_derived_flags (PFS_thread *pfs)
 
void update_thread_derived_flags ()
 Update derived flags for all thread instances. More...
 
void update_instruments_derived_flags ()
 Update derived flags for all instruments. More...
 
static void fct_reset_source_file_pointers (PFS_thread *pfs_thread)
 For each thread, clear the source file pointers from all waits, stages, statements and transaction events. More...
 
void reset_source_file_pointers ()
 Clear the source file pointers from all waits, stages, statements and transaction events. More...
 
std::atomic< uint32pfs_unload_plugin_ref_count (0)
 Global performance schema reference count for plugin and component events. More...
 
static void configure_instr_class (PFS_instr_class *entry)
 Set user-defined configuration values for an instrument. More...
 
static void init_instr_class (PFS_instr_class *klass, const char *name, uint name_length, int flags, int volatility, const char *documentation, PFS_class_type class_type)
 
void init_event_name_sizing (const PFS_global_param *param)
 
void register_global_classes ()
 
int init_sync_class (uint mutex_class_sizing, uint rwlock_class_sizing, uint cond_class_sizing)
 Initialize the instrument synch class buffers. More...
 
void cleanup_sync_class (void)
 Cleanup the instrument synch class buffers. More...
 
int init_thread_class (uint thread_class_sizing)
 Initialize the thread class buffer. More...
 
void cleanup_thread_class (void)
 Cleanup the thread class buffers. More...
 
int init_table_share (uint table_share_sizing)
 Initialize the table share buffer. More...
 
void cleanup_table_share (void)
 Cleanup the table share buffers. More...
 
static const uchartable_share_hash_get_key (const uchar *entry, size_t *length)
 get_key function for table_share_hash. More...
 
int init_table_share_hash (const PFS_global_param *param)
 Initialize the table share hash table. More...
 
void cleanup_table_share_hash (void)
 Cleanup the table share hash table. More...
 
static LF_PINSget_table_share_hash_pins (PFS_thread *thread)
 Get the hash pins for. More...
 
static void set_table_share_key (PFS_table_share_key *key, bool temporary, const char *schema_name, size_t schema_name_length, const char *table_name, size_t table_name_length)
 Set a table share hash key. More...
 
int init_table_share_lock_stat (uint table_stat_sizing)
 Initialize the table lock stat buffer. More...
 
PFS_table_share_lockcreate_table_share_lock_stat ()
 Create a table share lock instrumentation. More...
 
void release_table_share_lock_stat (PFS_table_share_lock *pfs)
 Release a table share lock instrumentation. More...
 
void cleanup_table_share_lock_stat (void)
 Cleanup the table stat buffers. More...
 
int init_table_share_index_stat (uint index_stat_sizing)
 Initialize table index stat buffer. More...
 
PFS_table_share_indexcreate_table_share_index_stat (const TABLE_SHARE *server_share, uint server_index)
 Create a table share index instrumentation. More...
 
void release_table_share_index_stat (PFS_table_share_index *pfs)
 Release a table share index instrumentation. More...
 
void cleanup_table_share_index_stat (void)
 Cleanup the table stat buffers. More...
 
int init_file_class (uint file_class_sizing)
 Initialize the file class buffer. More...
 
void cleanup_file_class (void)
 Cleanup the file class buffers. More...
 
int init_stage_class (uint stage_class_sizing)
 Initialize the stage class buffer. More...
 
void cleanup_stage_class (void)
 Cleanup the stage class buffers. More...
 
int init_statement_class (uint statement_class_sizing)
 Initialize the statement class buffer. More...
 
void cleanup_statement_class (void)
 Cleanup the statement class buffers. More...
 
int init_socket_class (uint socket_class_sizing)
 Initialize the socket class buffer. More...
 
void cleanup_socket_class (void)
 Cleanup the socket class buffers. More...
 
int init_memory_class (uint memory_class_sizing)
 Initialize the memory class buffer. More...
 
void cleanup_memory_class (void)
 Cleanup the memory class buffers. More...
 
PFS_sync_key register_mutex_class (const char *name, uint name_length, PSI_mutex_info *info)
 Register a mutex instrumentation metadata. More...
 
PFS_sync_key register_rwlock_class (const char *name, uint name_length, PSI_rwlock_info *info)
 Register a rwlock instrumentation metadata. More...
 
PFS_sync_key register_cond_class (const char *name, uint name_length, PSI_cond_info *info)
 Register a condition instrumentation metadata. More...
 
PFS_mutex_classfind_mutex_class (PFS_sync_key key)
 Find a mutex instrumentation class by key. More...
 
PFS_mutex_classsanitize_mutex_class (PFS_mutex_class *unsafe)
 
PFS_rwlock_classfind_rwlock_class (PFS_sync_key key)
 Find a rwlock instrumentation class by key. More...
 
PFS_rwlock_classsanitize_rwlock_class (PFS_rwlock_class *unsafe)
 
PFS_cond_classfind_cond_class (PFS_sync_key key)
 Find a condition instrumentation class by key. More...
 
PFS_cond_classsanitize_cond_class (PFS_cond_class *unsafe)
 
PFS_thread_key register_thread_class (const char *name, uint name_length, PSI_thread_info *info)
 Register a thread instrumentation metadata. More...
 
PFS_thread_classfind_thread_class (PFS_sync_key key)
 Find a thread instrumentation class by key. More...
 
PFS_thread_classsanitize_thread_class (PFS_thread_class *unsafe)
 
PFS_file_key register_file_class (const char *name, uint name_length, PSI_file_info *info)
 Register a file instrumentation metadata. More...
 
PFS_stage_key register_stage_class (const char *name, uint prefix_length, uint name_length, PSI_stage_info *info)
 Register a stage instrumentation metadata. More...
 
PFS_statement_key register_statement_class (const char *name, uint name_length, PSI_statement_info *info)
 Register a statement instrumentation metadata. More...
 
PFS_file_classfind_file_class (PFS_file_key key)
 Find a file instrumentation class by key. More...
 
PFS_file_classsanitize_file_class (PFS_file_class *unsafe)
 
PFS_stage_classfind_stage_class (PFS_stage_key key)
 Find a stage instrumentation class by key. More...
 
PFS_stage_classsanitize_stage_class (PFS_stage_class *unsafe)
 
PFS_statement_classfind_statement_class (PFS_stage_key key)
 Find a statement instrumentation class by key. More...
 
PFS_statement_classsanitize_statement_class (PFS_statement_class *unsafe)
 
PFS_socket_key register_socket_class (const char *name, uint name_length, PSI_socket_info *info)
 Register a socket instrumentation metadata. More...
 
PFS_socket_classfind_socket_class (PFS_socket_key key)
 Find a socket instrumentation class by key. More...
 
PFS_socket_classsanitize_socket_class (PFS_socket_class *unsafe)
 
PFS_memory_key register_memory_class (const char *name, uint name_length, PSI_memory_info *info)
 Register a memory instrumentation metadata. More...
 
PFS_memory_classfind_memory_class (PFS_memory_key key)
 Find a memory instrumentation class by key. More...
 
PFS_memory_classsanitize_memory_class (PFS_memory_class *unsafe)
 
PFS_instr_classfind_table_class (uint index)
 
PFS_instr_classsanitize_table_class (PFS_instr_class *unsafe)
 
PFS_instr_classfind_idle_class (uint index)
 
PFS_instr_classsanitize_idle_class (PFS_instr_class *unsafe)
 
PFS_instr_classfind_metadata_class (uint index)
 
PFS_instr_classsanitize_metadata_class (PFS_instr_class *unsafe)
 
PFS_error_classfind_error_class (uint index)
 
PFS_error_classsanitize_error_class (PFS_error_class *unsafe)
 
PFS_transaction_classfind_transaction_class (uint index)
 
PFS_transaction_classsanitize_transaction_class (PFS_transaction_class *unsafe)
 
static int compare_keys (PFS_table_share *pfs, const TABLE_SHARE *share)
 
PFS_table_sharefind_or_create_table_share (PFS_thread *thread, bool temporary, const TABLE_SHARE *share)
 Find or create a table share instrumentation. More...
 
void release_table_share (PFS_table_share *pfs)
 
void drop_table_share (PFS_thread *thread, bool temporary, const char *schema_name, uint schema_name_length, const char *table_name, uint table_name_length)
 Drop the instrumented table share associated with a table. More...
 
PFS_table_sharesanitize_table_share (PFS_table_share *unsafe)
 Sanitize an unsafe table_share pointer. More...
 
void reset_events_waits_by_class ()
 Reset the wait statistics per instrument class. More...
 
void reset_file_class_io (void)
 Reset the I/O statistics per file class. More...
 
void reset_socket_class_io (void)
 Reset the I/O statistics per socket class. More...
 
void update_table_share_derived_flags (PFS_thread *thread)
 Update derived flags for all table shares. More...
 
void update_program_share_derived_flags (PFS_thread *thread)
 Update derived flags for all stored procedure shares. More...
 
ulonglong gtid_monitoring_getsystime ()
 Get current time for GTID monitoring. More...
 
uint sanitize_index_count (uint count)
 
PFS_error_classsanitize_error_class (PFS_instr_class *unsafe)
 
int init_setup_actor (const PFS_global_param *param)
 Initialize the setup actor buffers. More...
 
void cleanup_setup_actor (void)
 Cleanup all the setup actor buffers. More...
 
static const ucharsetup_actor_hash_get_key (const uchar *entry, size_t *length)
 
int init_setup_actor_hash (const PFS_global_param *param)
 Initialize the setup actor hash. More...
 
void cleanup_setup_actor_hash (void)
 Cleanup the setup actor hash. More...
 
static LF_PINSget_setup_actor_hash_pins (PFS_thread *thread)
 
static void set_setup_actor_key (PFS_setup_actor_key *key, const char *user, uint user_length, const char *host, uint host_length, const char *role, uint role_length)
 
int insert_setup_actor (const String *user, const String *host, const String *role, bool enabled, bool history)
 
int delete_setup_actor (const String *user, const String *host, const String *role)
 
int reset_setup_actor ()
 
long setup_actor_count ()
 
void lookup_setup_actor (PFS_thread *thread, const char *user, uint user_length, const char *host, uint host_length, bool *enabled, bool *history)
 
int update_setup_actors_derived_flags ()
 Update derived flags for all setup_actors. More...
 
int init_setup_object (const PFS_global_param *param)
 Initialize the setup object buffers. More...
 
void cleanup_setup_object (void)
 Cleanup all the setup object buffers. More...
 
static const ucharsetup_object_hash_get_key (const uchar *entry, size_t *length)
 
int init_setup_object_hash (const PFS_global_param *param)
 Initialize the setup objects hash. More...
 
void cleanup_setup_object_hash (void)
 Cleanup the setup objects hash. More...
 
static LF_PINSget_setup_object_hash_pins (PFS_thread *thread)
 
static void set_setup_object_key (PFS_setup_object_key *key, enum_object_type object_type, const char *schema, uint schema_length, const char *object, uint object_length)
 
int insert_setup_object (enum_object_type object_type, const String *schema, const String *object, bool enabled, bool timed)
 
int delete_setup_object (enum_object_type object_type, const String *schema, const String *object)
 
int reset_setup_object ()
 
long setup_object_count ()
 
void lookup_setup_object (PFS_thread *thread, enum_object_type object_type, const char *schema_name, int schema_name_length, const char *object_name, int object_name_length, bool *enabled, bool *timed)
 
template<typename F , typename T >
void memory_partial_aggregate (F *from, T *stat)
 
template<typename F , typename T >
void memory_partial_aggregate (F *from, T *stat1, T *stat2)
 
template<typename F , typename T >
void memory_full_aggregate (const F *from, T *stat)
 
template<typename F , typename T >
void memory_full_aggregate (const F *from, T *stat1, T *stat2)
 
int init_user (const PFS_global_param *param)
 Initialize the user buffers. More...
 
void cleanup_user (void)
 Cleanup all the user buffers. More...
 
static const ucharuser_hash_get_key (const uchar *entry, size_t *length)
 
int init_user_hash (const PFS_global_param *param)
 Initialize the user hash. More...
 
void cleanup_user_hash (void)
 Cleanup the user hash. More...
 
static LF_PINSget_user_hash_pins (PFS_thread *thread)
 
static void set_user_key (PFS_user_key *key, const char *user, uint user_length)
 
PFS_userfind_or_create_user (PFS_thread *thread, const char *username, uint username_length)
 
PFS_usersanitize_user (PFS_user *unsafe)
 
static void purge_user (PFS_thread *thread, PFS_user *user)
 
void purge_all_user (void)
 Purge non connected users, reset stats of connected users. More...
 
static PFS_threadget_pfs_from_THD (THD *thd)
 
void PFS_account::aggregate (bool alive, PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_waits (PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_stages (PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_statements (PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_transactions (PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_errors (PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_memory (bool alive, PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_status (PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::aggregate_stats (PFS_user *safe_user, PFS_host *safe_host)
 
void PFS_account::release (void)
 
void PFS_account::rebase_memory_stats ()
 Reset all memory statistics. More...
 
void PFS_account::carry_memory_stat_delta (PFS_memory_stat_delta *delta, uint index)
 
void PFS_connection_slice::reset_waits_stats ()
 Reset all wait statistics. More...
 
void PFS_connection_slice::reset_stages_stats ()
 Reset all stages statistics. More...
 
void PFS_connection_slice::reset_statements_stats ()
 Reset all statements statistics. More...
 
void PFS_connection_slice::reset_transactions_stats ()
 Reset all transactions statistics. More...
 
void PFS_connection_slice::reset_errors_stats ()
 Reset all errors statistics. More...
 
void PFS_host::aggregate (bool alive)
 
void PFS_host::aggregate_waits (void)
 
void PFS_host::aggregate_stages (void)
 
void PFS_host::aggregate_statements (void)
 
void PFS_host::aggregate_transactions (void)
 
void PFS_host::aggregate_errors (void)
 
void PFS_host::aggregate_memory (bool alive)
 
void PFS_host::aggregate_status (void)
 
void PFS_host::aggregate_stats (void)
 
void PFS_host::release (void)
 
void PFS_host::rebase_memory_stats ()
 Reset all memory statistics. More...
 
void PFS_host::carry_memory_stat_delta (PFS_memory_stat_delta *delta, uint index)
 
static PFS_threadPFS_thread::get_current_thread (void)
 
void PFS_thread::reset_session_connect_attrs ()
 Reset session connect attributes. More...
 
void PFS_thread::set_history_derived_flags ()
 
void PFS_thread::rebase_memory_stats ()
 Reset all memory statistics. More...
 
void PFS_thread::carry_memory_stat_delta (PFS_memory_stat_delta *delta, uint index)
 
void PFS_table::sanitized_aggregate (void)
 Aggregate this table handle statistics to the parents. More...
 
void PFS_table::sanitized_aggregate_io (void)
 Aggregate this table handle I/O statistics to the parents. More...
 
void PFS_table::sanitized_aggregate_lock (void)
 Aggregate this table handle lock statistics to the parents. More...
 
static void PFS_table::safe_aggregate_io (const TABLE_SHARE *optional_server_share, PFS_table_stat *stat, PFS_table_share *safe_share)
 
static void PFS_table::safe_aggregate_lock (PFS_table_stat *stat, PFS_table_share *safe_share)
 
PFS_table_share_lockPFS_table_share::find_lock_stat () const
 Find an existing table share lock instrumentation. More...
 
PFS_table_share_lockPFS_table_share::find_or_create_lock_stat ()
 Find or create a table share lock instrumentation. More...
 
void PFS_table_share::destroy_lock_stat ()
 Destroy a table share lock instrumentation. More...
 
PFS_table_share_indexPFS_table_share::find_index_stat (uint index) const
 Find an existing table share index instrumentation. More...
 
PFS_table_share_indexPFS_table_share::find_or_create_index_stat (const TABLE_SHARE *server_share, uint index)
 Find or create a table share index instrumentation. More...
 
void PFS_table_share::destroy_index_stats ()
 Destroy table share index instrumentation. More...
 
void PFS_table_share::refresh_setup_object_flags (PFS_thread *thread)
 
void PFS_table_share::aggregate_io (void)
 
void PFS_table_share::sum_io (PFS_single_stat *result, uint key_count)
 
void PFS_table_share::sum_lock (PFS_single_stat *result)
 
void PFS_table_share::sum (PFS_single_stat *result, uint key_count)
 
void PFS_table_share::aggregate_lock (void)
 
void PFS_user::aggregate (bool alive)
 
void PFS_user::aggregate_waits (void)
 
void PFS_user::aggregate_stages (void)
 
void PFS_user::aggregate_statements (void)
 
void PFS_user::aggregate_transactions (void)
 
void PFS_user::aggregate_errors (void)
 
void PFS_user::aggregate_memory (bool alive)
 
void PFS_user::aggregate_status (void)
 
void PFS_user::aggregate_stats (void)
 
void PFS_user::release (void)
 
void PFS_user::rebase_memory_stats ()
 Reset all memory statistics. More...
 
void PFS_user::carry_memory_stat_delta (PFS_memory_stat_delta *delta, uint index)
 
static void PFS_connection_iterator::visit_global (bool with_hosts, bool with_users, bool with_accounts, bool with_threads, bool with_THDs, PFS_connection_visitor *visitor)
 Visit all connections. More...
 
static void PFS_connection_iterator::visit_host (PFS_host *host, bool with_accounts, bool with_threads, bool with_THDs, PFS_connection_visitor *visitor)
 Visit all connections of a host. More...
 
static void PFS_connection_iterator::visit_user (PFS_user *user, bool with_accounts, bool with_threads, bool with_THDs, PFS_connection_visitor *visitor)
 Visit all connections of a user. More...
 
static void PFS_connection_iterator::visit_account (PFS_account *account, bool with_threads, bool with_THDs, PFS_connection_visitor *visitor)
 Visit all connections of a user+host. More...
 
static void PFS_connection_iterator::visit_THD (THD *thd, PFS_connection_visitor *visitor)
 Visit THD. More...
 
static void PFS_instance_iterator::visit_all (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_mutex (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_mutex_classes (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_mutex_instances (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_rwlock (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_rwlock_classes (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_rwlock_instances (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_cond (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_cond_classes (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_cond_instances (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_file (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_file_classes (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_all_file_instances (PFS_instance_visitor *visitor)
 
static void PFS_instance_iterator::visit_mutex_instances (PFS_mutex_class *klass, PFS_instance_visitor *visitor)
 Visit a mutex class and related instances. More...
 
static void PFS_instance_iterator::visit_rwlock_instances (PFS_rwlock_class *klass, PFS_instance_visitor *visitor)
 Visit a rwlock class and related instances. More...
 
static void PFS_instance_iterator::visit_cond_instances (PFS_cond_class *klass, PFS_instance_visitor *visitor)
 Visit a cond class and related instances. More...
 
static void PFS_instance_iterator::visit_file_instances (PFS_file_class *klass, PFS_instance_visitor *visitor)
 Visit a file class and related instances. More...
 
static void PFS_instance_iterator::visit_socket_instances (PFS_socket_class *klass, PFS_instance_visitor *visitor)
 Visit a socket class and related instances. More...
 
static void PFS_instance_iterator::visit_socket_instances (PFS_socket_class *klass, PFS_instance_visitor *visitor, PFS_thread *thread, bool visit_class=true)
 Visit a socket class and related instances. More...
 
static void PFS_instance_iterator::visit_instances (PFS_instr_class *klass, PFS_instance_visitor *visitor, PFS_thread *thread, bool visit_class=true)
 Visit an instrument class and related instances. More...
 
static void PFS_object_iterator::visit_all (PFS_object_visitor *visitor)
 Visit all objects. More...
 
static void PFS_object_iterator::visit_all_tables (PFS_object_visitor *visitor)
 Visit all tables and related handles. More...
 
static void PFS_object_iterator::visit_tables (PFS_table_share *share, PFS_object_visitor *visitor)
 Visit a table and related table handles. More...
 
static void PFS_object_iterator::visit_table_indexes (PFS_table_share *share, uint index, PFS_object_visitor *visitor)
 Visit a table index and related table handles indexes. More...
 
 PFS_connection_wait_visitor::PFS_connection_wait_visitor (PFS_instr_class *klass)
 Constructor. More...
 
virtual PFS_connection_wait_visitor::~PFS_connection_wait_visitor ()
 
virtual void PFS_connection_wait_visitor::visit_global ()
 Visit all connections. More...
 
virtual void PFS_connection_wait_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_wait_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_wait_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_wait_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_all_wait_visitor::PFS_connection_all_wait_visitor ()
 Constructor. More...
 
virtual PFS_connection_all_wait_visitor::~PFS_connection_all_wait_visitor ()
 
virtual void PFS_connection_all_wait_visitor::visit_global ()
 Visit all connections. More...
 
void PFS_connection_all_wait_visitor::visit_connection_slice (PFS_connection_slice *pfs)
 
virtual void PFS_connection_all_wait_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_all_wait_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_all_wait_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_all_wait_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_stage_visitor::PFS_connection_stage_visitor (PFS_stage_class *klass)
 Constructor. More...
 
virtual PFS_connection_stage_visitor::~PFS_connection_stage_visitor ()
 
virtual void PFS_connection_stage_visitor::visit_global ()
 Visit all connections. More...
 
virtual void PFS_connection_stage_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_stage_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_stage_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_stage_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_statement_visitor::PFS_connection_statement_visitor (PFS_statement_class *klass)
 Constructor. More...
 
virtual PFS_connection_statement_visitor::~PFS_connection_statement_visitor ()
 
virtual void PFS_connection_statement_visitor::visit_global ()
 Visit all connections. More...
 
virtual void PFS_connection_statement_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_statement_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_statement_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_statement_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_all_statement_visitor::PFS_connection_all_statement_visitor ()
 Constructor. More...
 
virtual PFS_connection_all_statement_visitor::~PFS_connection_all_statement_visitor ()
 
virtual void PFS_connection_all_statement_visitor::visit_global ()
 Visit all connections. More...
 
void PFS_connection_all_statement_visitor::visit_connection_slice (PFS_connection_slice *pfs)
 
virtual void PFS_connection_all_statement_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_all_statement_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_all_statement_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_all_statement_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_transaction_visitor::PFS_connection_transaction_visitor (PFS_transaction_class *klass)
 Constructor. More...
 
virtual PFS_connection_transaction_visitor::~PFS_connection_transaction_visitor ()
 
virtual void PFS_connection_transaction_visitor::visit_global ()
 Visit all connections. More...
 
virtual void PFS_connection_transaction_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_transaction_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_transaction_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_transaction_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_error_visitor::PFS_connection_error_visitor (PFS_error_class *klass, int index)
 Constructor. More...
 
virtual PFS_connection_error_visitor::~PFS_connection_error_visitor ()
 
virtual void PFS_connection_error_visitor::visit_global ()
 Visit all connections. More...
 
virtual void PFS_connection_error_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_error_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_error_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_error_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_stat_visitor::PFS_connection_stat_visitor ()
 Constructor. More...
 
virtual PFS_connection_stat_visitor::~PFS_connection_stat_visitor ()
 
virtual void PFS_connection_stat_visitor::visit_global ()
 Visit all connections. More...
 
virtual void PFS_connection_stat_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_stat_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_stat_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_stat_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_memory_visitor::PFS_connection_memory_visitor (PFS_memory_class *klass)
 Constructor. More...
 
virtual PFS_connection_memory_visitor::~PFS_connection_memory_visitor ()
 
virtual void PFS_connection_memory_visitor::visit_global ()
 Visit all connections. More...
 
virtual void PFS_connection_memory_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_memory_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_memory_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_memory_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
 PFS_connection_status_visitor::PFS_connection_status_visitor (System_status_var *status_vars)
 Constructor. More...
 
virtual PFS_connection_status_visitor::~PFS_connection_status_visitor ()
 
virtual void PFS_connection_status_visitor::visit_global ()
 Aggregate from global status. More...
 
virtual void PFS_connection_status_visitor::visit_host (PFS_host *pfs)
 Visit all connections of a host. More...
 
virtual void PFS_connection_status_visitor::visit_user (PFS_user *pfs)
 Visit all connections of a user. More...
 
virtual void PFS_connection_status_visitor::visit_account (PFS_account *pfs)
 Visit all connections of a user+host. More...
 
virtual void PFS_connection_status_visitor::visit_thread (PFS_thread *pfs)
 Visit a thread. More...
 
virtual void PFS_connection_status_visitor::visit_THD (THD *thd)
 Visit a THD associated with a thread. More...
 
 PFS_instance_wait_visitor::PFS_instance_wait_visitor ()
 
virtual PFS_instance_wait_visitor::~PFS_instance_wait_visitor ()
 
virtual void PFS_instance_wait_visitor::visit_mutex_class (PFS_mutex_class *pfs)
 Visit a mutex class. More...
 
virtual void PFS_instance_wait_visitor::visit_rwlock_class (PFS_rwlock_class *pfs)
 Visit a rwlock class. More...
 
virtual void PFS_instance_wait_visitor::visit_cond_class (PFS_cond_class *pfs)
 Visit a cond class. More...
 
virtual void PFS_instance_wait_visitor::visit_file_class (PFS_file_class *pfs)
 Visit a file class. More...
 
virtual void PFS_instance_wait_visitor::visit_socket_class (PFS_socket_class *pfs)
 Visit a socket class. More...
 
virtual void PFS_instance_wait_visitor::visit_mutex (PFS_mutex *pfs)
 Visit a mutex instance. More...
 
virtual void PFS_instance_wait_visitor::visit_rwlock (PFS_rwlock *pfs)
 Visit a rwlock instance. More...
 
virtual void PFS_instance_wait_visitor::visit_cond (PFS_cond *pfs)
 Visit a cond instance. More...
 
virtual void PFS_instance_wait_visitor::visit_file (PFS_file *pfs)
 Visit a file instance. More...
 
virtual void PFS_instance_wait_visitor::visit_socket (PFS_socket *pfs)
 Visit a socket instance. More...
 
 PFS_object_wait_visitor::PFS_object_wait_visitor ()
 Table I/O wait visitor. More...
 
virtual PFS_object_wait_visitor::~PFS_object_wait_visitor ()
 
virtual void PFS_object_wait_visitor::visit_global ()
 Visit global data. More...
 
virtual void PFS_object_wait_visitor::visit_table_share (PFS_table_share *pfs)
 Visit a table share. More...
 
virtual void PFS_object_wait_visitor::visit_table (PFS_table *pfs)
 Visit a table. More...
 
 PFS_table_io_wait_visitor::PFS_table_io_wait_visitor ()
 
virtual PFS_table_io_wait_visitor::~PFS_table_io_wait_visitor ()
 
virtual void PFS_table_io_wait_visitor::visit_global ()
 Visit global data. More...
 
virtual void PFS_table_io_wait_visitor::visit_table_share (PFS_table_share *pfs)
 Visit a table share. More...
 
virtual void PFS_table_io_wait_visitor::visit_table (PFS_table *pfs)
 Visit a table. More...
 
 PFS_table_io_stat_visitor::PFS_table_io_stat_visitor ()
 Table I/O stat visitor. More...
 
virtual PFS_table_io_stat_visitor::~PFS_table_io_stat_visitor ()
 
virtual void PFS_table_io_stat_visitor::visit_table_share (PFS_table_share *pfs)
 Visit a table share. More...
 
virtual void PFS_table_io_stat_visitor::visit_table (PFS_table *pfs)
 Visit a table. More...
 
 PFS_index_io_stat_visitor::PFS_index_io_stat_visitor ()
 Index I/O stat visitor. More...
 
virtual PFS_index_io_stat_visitor::~PFS_index_io_stat_visitor ()
 
virtual void PFS_index_io_stat_visitor::visit_table_share_index (PFS_table_share *pfs, uint index)
 Visit a table share index. More...
 
virtual void PFS_index_io_stat_visitor::visit_table_index (PFS_table *pfs, uint index)
 Visit a table index. More...
 
 PFS_table_lock_wait_visitor::PFS_table_lock_wait_visitor ()
 Table lock wait visitor. More...
 
virtual PFS_table_lock_wait_visitor::~PFS_table_lock_wait_visitor ()
 
virtual void PFS_table_lock_wait_visitor::visit_global ()
 Visit global data. More...
 
virtual void PFS_table_lock_wait_visitor::visit_table_share (PFS_table_share *pfs)
 Visit a table share. More...
 
virtual void PFS_table_lock_wait_visitor::visit_table (PFS_table *pfs)
 Visit a table. More...
 
 PFS_table_lock_stat_visitor::PFS_table_lock_stat_visitor ()
 Table lock stat visitor. More...
 
virtual PFS_table_lock_stat_visitor::~PFS_table_lock_stat_visitor ()
 
virtual void PFS_table_lock_stat_visitor::visit_table_share (PFS_table_share *pfs)
 Visit a table share. More...
 
virtual void PFS_table_lock_stat_visitor::visit_table (PFS_table *pfs)
 Visit a table. More...
 
 PFS_instance_socket_io_stat_visitor::PFS_instance_socket_io_stat_visitor ()
 
virtual PFS_instance_socket_io_stat_visitor::~PFS_instance_socket_io_stat_visitor ()
 
virtual void PFS_instance_socket_io_stat_visitor::visit_socket_class (PFS_socket_class *pfs)
 Visit a socket class. More...
 
virtual void PFS_instance_socket_io_stat_visitor::visit_socket (PFS_socket *pfs)
 Visit a socket instance. More...
 
 PFS_instance_file_io_stat_visitor::PFS_instance_file_io_stat_visitor ()
 
virtual PFS_instance_file_io_stat_visitor::~PFS_instance_file_io_stat_visitor ()
 
virtual void PFS_instance_file_io_stat_visitor::visit_file_class (PFS_file_class *pfs)
 Visit a file class. More...
 
virtual void PFS_instance_file_io_stat_visitor::visit_file (PFS_file *pfs)
 Visit a file instance. More...
 

Variables

LF_HASH account_hash
 
static bool account_hash_inited = false
 
LF_HASH account_hash
 
LF_HASH host_hash
 
static bool host_hash_inited = false
 
LF_HASH host_hash
 
long file_handle_max = 0
 Size of the file handle array. More...
 
bool file_handle_full
 True when file_handle_array is full. More...
 
ulong file_handle_lost = 0
 Number of file handle lost. More...
 
ulong events_waits_history_per_thread = 0
 Number of EVENTS_WAITS_HISTORY records per thread. More...
 
ulong events_stages_history_per_thread = 0
 Number of EVENTS_STAGES_HISTORY records per thread. More...
 
ulong events_statements_history_per_thread = 0
 Number of EVENTS_STATEMENTS_HISTORY records per thread. More...
 
uint statement_stack_max = 0
 Max size of the statements stack. More...
 
size_t pfs_max_digest_length = 0
 Max size of the digests token array. More...
 
size_t pfs_max_sqltext = 0
 Max size of SQL TEXT. More...
 
ulong locker_lost = 0
 Number of locker lost. More...
 
ulong statement_lost = 0
 Number of statements lost. More...
 
ulong session_connect_attrs_size_per_thread
 Size of connection attribute storage per thread. More...
 
ulong session_connect_attrs_longest_seen = 0
 Longest connection attributes string seen so far, pre-truncation. More...
 
ulong session_connect_attrs_lost = 0
 Number of connection attributes lost. More...
 
ulong events_transactions_history_per_thread = 0
 Number of EVENTS_TRANSACTIONS_HISTORY records per thread. More...
 
PFS_file ** file_handle_array = NULL
 File instrumentation handle array. More...
 
PFS_stage_statglobal_instr_class_stages_array = NULL
 
PFS_statement_statglobal_instr_class_statements_array = NULL
 
PFS_histogram global_statements_histogram
 
std::atomic< PFS_memory_shared_stat * > global_instr_class_memory_array {nullptr}
 
static PFS_cacheline_atomic_uint64 thread_internal_id_counter
 
LF_HASH filename_hash
 Hash table for instrumented files. More...
 
static bool filename_hash_inited = false
 True if filename_hash is initialized. More...
 
uint statement_stack_max
 Max size of the statements stack. More...
 
size_t pfs_max_digest_length
 Max size of the digests token array. More...
 
size_t pfs_max_sqltext
 Max size of SQL TEXT. More...
 
PFS_stage_statglobal_instr_class_stages_array
 
PFS_statement_statglobal_instr_class_statements_array
 
PFS_histogram global_statements_histogram
 
std::atomic< PFS_memory_shared_stat * > global_instr_class_memory_array
 
long file_handle_max
 Size of the file handle array. More...
 
ulong file_handle_lost
 Number of file handle lost. More...
 
ulong events_waits_history_per_thread
 Number of EVENTS_WAITS_HISTORY records per thread. More...
 
ulong events_stages_history_per_thread
 Number of EVENTS_STAGES_HISTORY records per thread. More...
 
ulong events_statements_history_per_thread
 Number of EVENTS_STATEMENTS_HISTORY records per thread. More...
 
ulong events_transactions_history_per_thread
 Number of EVENTS_TRANSACTIONS_HISTORY records per thread. More...
 
ulong locker_lost
 Number of locker lost. More...
 
ulong statement_lost
 Number of statements lost. More...
 
ulong session_connect_attrs_lost
 Number of connection attributes lost. More...
 
ulong session_connect_attrs_longest_seen
 Longest connection attributes string seen so far, pre-truncation. More...
 
ulong session_connect_attrs_size_per_thread
 Size of connection attribute storage per thread. More...
 
PFS_file ** file_handle_array
 File instrumentation handle array. More...
 
LF_HASH filename_hash
 Hash table for instrumented files. More...
 
bool pfs_enabled = true
 Global performance schema flag. More...
 
Pfs_instr_config_arraypfs_instr_config_array = NULL
 PFS_INSTRUMENT option settings array. More...
 
static std::atomic< uint32mutex_class_dirty_count {0}
 Current number of elements in mutex_class_array. More...
 
static std::atomic< uint32mutex_class_allocated_count {0}
 
static std::atomic< uint32rwlock_class_dirty_count {0}
 
static std::atomic< uint32rwlock_class_allocated_count {0}
 
static std::atomic< uint32cond_class_dirty_count {0}
 
static std::atomic< uint32cond_class_allocated_count {0}
 
ulong mutex_class_max = 0
 Size of the mutex class array. More...
 
ulong mutex_class_lost = 0
 Number of mutex class lost. More...
 
ulong rwlock_class_max = 0
 Size of the rwlock class array. More...
 
ulong rwlock_class_lost = 0
 Number of rwlock class lost. More...
 
ulong cond_class_max = 0
 Size of the condition class array. More...
 
ulong cond_class_lost = 0
 Number of condition class lost. More...
 
ulong thread_class_max = 0
 Size of the thread class array. More...
 
ulong thread_class_lost = 0
 Number of thread class lost. More...
 
ulong file_class_max = 0
 Size of the file class array. More...
 
ulong file_class_lost = 0
 Number of file class lost. More...
 
ulong stage_class_max = 0
 Size of the stage class array. More...
 
ulong stage_class_lost = 0
 Number of stage class lost. More...
 
ulong statement_class_max = 0
 Size of the statement class array. More...
 
ulong statement_class_lost = 0
 Number of statement class lost. More...
 
ulong socket_class_max = 0
 Size of the socket class array. More...
 
ulong socket_class_lost = 0
 Number of socket class lost. More...
 
ulong memory_class_max = 0
 Size of the memory class array. More...
 
ulong memory_class_lost = 0
 Number of memory class lost. More...
 
ulong transaction_class_max = 0
 Number of transaction classes. More...
 
ulong error_class_max = 0
 Number of error classes. More...
 
PFS_mutex_classmutex_class_array = NULL
 
PFS_rwlock_classrwlock_class_array = NULL
 
PFS_cond_classcond_class_array = NULL
 
static std::atomic< uint32thread_class_dirty_count {0}
 Current number or elements in thread_class_array. More...
 
static std::atomic< uint32thread_class_allocated_count {0}
 
static PFS_thread_classthread_class_array = NULL
 
PFS_ALIGNED PFS_single_stat global_idle_stat
 Statistics for the IDLE instrument. More...
 
PFS_ALIGNED PFS_table_io_stat global_table_io_stat
 Statistics for dropped table I/O. More...
 
PFS_ALIGNED PFS_table_lock_stat global_table_lock_stat
 Statistics for dropped table lock. More...
 
PFS_ALIGNED PFS_single_stat global_metadata_stat
 Statistics for the METADATA instrument. More...
 
PFS_ALIGNED PFS_transaction_stat global_transaction_stat
 Statistics for the transaction instrument. More...
 
PFS_ALIGNED PFS_error_stat global_error_stat
 Statistics for the error instrument. More...
 
PFS_ALIGNED PFS_instr_class global_table_io_class
 Instrument controlling all table I/O. More...
 
PFS_ALIGNED PFS_instr_class global_table_lock_class
 Instrument controlling all table lock. More...
 
PFS_ALIGNED PFS_instr_class global_idle_class
 Instrument controlling all idle waits. More...
 
PFS_ALIGNED PFS_instr_class global_metadata_class
 Instrument controlling all metadata locks. More...
 
PFS_ALIGNED PFS_error_class global_error_class
 Instrument controlling all server errors. More...
 
PFS_ALIGNED PFS_transaction_class global_transaction_class
 
LF_HASH table_share_hash
 Hash index for instrumented table shares. More...
 
static bool table_share_hash_inited = false
 True if table_share_hash is initialized. More...
 
static std::atomic< uint32file_class_dirty_count {0}
 
static std::atomic< uint32file_class_allocated_count {0}
 
PFS_file_classfile_class_array = NULL
 
static std::atomic< uint32stage_class_dirty_count {0}
 
static std::atomic< uint32stage_class_allocated_count {0}
 
static PFS_stage_classstage_class_array = NULL
 
static std::atomic< uint32statement_class_dirty_count {0}
 
static std::atomic< uint32statement_class_allocated_count {0}
 
static PFS_statement_classstatement_class_array = NULL
 
static std::atomic< uint32socket_class_dirty_count {0}
 
static std::atomic< uint32socket_class_allocated_count {0}
 
static PFS_socket_classsocket_class_array = NULL
 
static std::atomic< uint32memory_class_dirty_count {0}
 
static std::atomic< uint32memory_class_allocated_count {0}
 
static std::atomic< PFS_memory_class * > memory_class_array {nullptr}
 
uint mutex_class_start = 0
 
uint rwlock_class_start = 0
 
uint cond_class_start = 0
 
uint file_class_start = 0
 
uint wait_class_max = 0
 
uint socket_class_start = 0
 
bool pfs_enabled
 Global performance schema flag. More...
 
std::atomic< uint32pfs_unload_plugin_ref_count
 Global ref count for plugin and component events. More...
 
Pfs_instr_config_arraypfs_instr_config_array
 PFS_INSTRUMENT option settings array. More...
 
uint mutex_class_start
 
uint rwlock_class_start
 
uint cond_class_start
 
uint file_class_start
 
uint socket_class_start
 
uint wait_class_max
 
PFS_single_stat global_idle_stat
 Statistics for the IDLE instrument. More...
 
PFS_table_io_stat global_table_io_stat
 Statistics for dropped table I/O. More...
 
PFS_table_lock_stat global_table_lock_stat
 Statistics for dropped table lock. More...
 
PFS_single_stat global_metadata_stat
 Statistics for the METADATA instrument. More...
 
PFS_transaction_stat global_transaction_stat
 Statistics for the transaction instrument. More...
 
PFS_error_stat global_error_stat
 Statistics for the error instrument. More...
 
PFS_instr_class global_table_io_class
 Instrument controlling all table I/O. More...
 
PFS_instr_class global_table_lock_class
 Instrument controlling all table lock. More...
 
PFS_instr_class global_idle_class
 Instrument controlling all idle waits. More...
 
PFS_instr_class global_metadata_class
 Instrument controlling all metadata locks. More...
 
PFS_error_class global_error_class
 Instrument controlling all server errors. More...
 
PFS_transaction_class global_transaction_class
 
ulong mutex_class_max
 Size of the mutex class array. More...
 
ulong mutex_class_lost
 Number of mutex class lost. More...
 
ulong rwlock_class_max
 Size of the rwlock class array. More...
 
ulong rwlock_class_lost
 Number of rwlock class lost. More...
 
ulong cond_class_max
 Size of the condition class array. More...
 
ulong cond_class_lost
 Number of condition class lost. More...
 
ulong thread_class_max
 Size of the thread class array. More...
 
ulong thread_class_lost
 Number of thread class lost. More...
 
ulong file_class_max
 Size of the file class array. More...
 
ulong file_class_lost
 Number of file class lost. More...
 
ulong stage_class_max
 Size of the stage class array. More...
 
ulong stage_class_lost
 Number of stage class lost. More...
 
ulong statement_class_max
 Size of the statement class array. More...
 
ulong statement_class_lost
 Number of statement class lost. More...
 
ulong transaction_class_max
 Number of transaction classes. More...
 
ulong socket_class_max
 Size of the socket class array. More...
 
ulong socket_class_lost
 Number of socket class lost. More...
 
ulong memory_class_max
 Size of the memory class array. More...
 
ulong memory_class_lost
 Number of memory class lost. More...
 
ulong error_class_max
 Number of error classes. More...
 
PFS_mutex_classmutex_class_array
 
PFS_rwlock_classrwlock_class_array
 
PFS_cond_classcond_class_array
 
PFS_file_classfile_class_array
 
LF_HASH table_share_hash
 Hash index for instrumented table shares. More...
 
LF_HASH setup_actor_hash
 Hash table for setup_actor records. More...
 
static bool setup_actor_hash_inited = false
 True if setup_actor_hash is initialized. More...
 
LF_HASH setup_actor_hash
 Hash table for setup_actor records. More...
 
uint setup_objects_version = 0
 
LF_HASH setup_object_hash
 
static bool setup_object_hash_inited = false
 
LF_HASH setup_object_hash
 
LF_HASH user_hash
 
static bool user_hash_inited = false
 
LF_HASH user_hash
 

Detailed Description

Macro Definition Documentation

◆ COUNT_GLOBAL_EVENT_INDEX

#define COUNT_GLOBAL_EVENT_INDEX   4

Number of global wait events.

◆ COUNT_PFS_TL_LOCK_TYPE

#define COUNT_PFS_TL_LOCK_TYPE   10

◆ FIND_CLASS_BODY

#define FIND_CLASS_BODY (   KEY,
  COUNT,
  ARRAY 
)
Value:
if ((KEY == 0) || (KEY > COUNT)) { \
return NULL; \
} \
return &ARRAY[KEY - 1]
Sergei Dialog Client Authentication NULL
Definition: dialog.cc:352
Definition: key.h:111

◆ GLOBAL_ERROR_INDEX

#define GLOBAL_ERROR_INDEX   0

◆ GLOBAL_IDLE_EVENT_INDEX

#define GLOBAL_IDLE_EVENT_INDEX   2

◆ GLOBAL_METADATA_EVENT_INDEX

#define GLOBAL_METADATA_EVENT_INDEX   3

◆ GLOBAL_TABLE_IO_EVENT_INDEX

#define GLOBAL_TABLE_IO_EVENT_INDEX   0

◆ GLOBAL_TABLE_LOCK_EVENT_INDEX

#define GLOBAL_TABLE_LOCK_EVENT_INDEX   1

◆ GLOBAL_TRANSACTION_INDEX

#define GLOBAL_TRANSACTION_INDEX   0

Transaction events are not wait events .

◆ PFS_LOCK_ALLOCATED

#define PFS_LOCK_ALLOCATED   0x02

State of an allocated record.

Values of an allocated record are safe to read by a reader. A writer may modify some but not all properties of the record: only modifying values that can never cause the reader to crash is allowed.

◆ PFS_LOCK_DIRTY

#define PFS_LOCK_DIRTY   0x01

State of a dirty record.

Values of a dirty record should not be read by a reader, as the record is currently being modified. Only one writer, the writer which owns the record, should modify the record content.

◆ PFS_LOCK_FREE

#define PFS_LOCK_FREE   0x00

State of a free record.

Values of a free record should not be read by a reader. Writers can concurrently attempt to allocate a free record.

◆ PFS_MEMORY_STAT_INITIALIZER

#define PFS_MEMORY_STAT_INITIALIZER   { false, 0, 0, 0, 0, 0, 0, 0, 0 }

◆ PFS_MUTEX_PARTITIONS

#define PFS_MUTEX_PARTITIONS   2

◆ REGISTER_CLASS_BODY_PART

#define REGISTER_CLASS_BODY_PART (   INDEX,
  ARRAY,
  MAX,
  NAME,
  NAME_LENGTH 
)
Value:
for (INDEX = 0; INDEX < MAX; INDEX++) { \
entry = &ARRAY[INDEX]; \
if ((entry->m_name_length == NAME_LENGTH) && \
(strncmp(entry->m_name, NAME, NAME_LENGTH) == 0)) { \
DBUG_ASSERT(entry->m_flags == info->m_flags); \
return (INDEX + 1); \
} \
}
const std::string INDEX("INDEX")
Log info(cout, "NOTE")
Definition: completion_hash.h:34

◆ STATE_MASK

#define STATE_MASK   0x00000003

◆ VERSION_INC

#define VERSION_INC   4

◆ VERSION_MASK

#define VERSION_MASK   0xFFFFFFFC

◆ WAIT_STACK_BOTTOM

#define WAIT_STACK_BOTTOM   1

Maximum number dummy waits records.

One dummy record is reserved for the parent stage / statement / transaction, at the bottom of the wait stack.

◆ WAIT_STACK_LOGICAL_SIZE

#define WAIT_STACK_LOGICAL_SIZE   5

Maximum number of nested waits.

Some waits, such as:

  • "wait/io/table/sql/handler"
  • "wait/lock/table/sql/handler" are implemented by calling code in a storage engine, that can cause nested waits (file I/O, mutex, ...) Because of partitioned tables, a table I/O event (on the whole table) can contain a nested table I/O event (on a partition). Because of additional debug instrumentation, waiting on what looks like a "mutex" (safe_mutex, innodb sync0sync, ...) can cause nested waits to be recorded. For example, a wait on innodb mutexes can lead to:
  • wait/sync/mutex/innobase/some_mutex
    • wait/sync/mutex/innobase/sync0sync
      • wait/sync/mutex/innobase/os0sync The max depth of the event stack must be sufficient for these low level details to be visible.

◆ WAIT_STACK_SIZE

#define WAIT_STACK_SIZE   (WAIT_STACK_BOTTOM + WAIT_STACK_LOGICAL_SIZE)

Physical size of the waits stack.

Typedef Documentation

◆ PFS_file_key

typedef unsigned int PFS_file_key

Key, naming a file instrument.

◆ Pfs_instr_config_array

◆ PFS_memory_key

typedef unsigned int PFS_memory_key

Key, naming a memory instrument.

◆ PFS_socket_key

typedef unsigned int PFS_socket_key

Key, naming a socket instrument.

◆ PFS_stage_key

typedef unsigned int PFS_stage_key

Key, naming a stage instrument.

◆ PFS_statement_key

typedef unsigned int PFS_statement_key

Key, naming a statement instrument.

◆ PFS_sync_key

typedef unsigned int PFS_sync_key

Key, naming a synch instrument (mutex, rwlock, cond).

◆ PFS_thread_key

typedef unsigned int PFS_thread_key

Key, naming a thread instrument.

◆ PFS_transaction_key

typedef unsigned int PFS_transaction_key

Key, naming a transaction instrument.

Enumeration Type Documentation

◆ PFS_class_type

Enumerator
PFS_CLASS_NONE 
PFS_CLASS_MUTEX 
PFS_CLASS_RWLOCK 
PFS_CLASS_COND 
PFS_CLASS_FILE 
PFS_CLASS_TABLE 
PFS_CLASS_STAGE 
PFS_CLASS_STATEMENT 
PFS_CLASS_TRANSACTION 
PFS_CLASS_SOCKET 
PFS_CLASS_TABLE_IO 
PFS_CLASS_TABLE_LOCK 
PFS_CLASS_IDLE 
PFS_CLASS_MEMORY 
PFS_CLASS_METADATA 
PFS_CLASS_ERROR 
PFS_CLASS_THREAD 
PFS_CLASS_LAST 
PFS_CLASS_MAX 

◆ PFS_TL_LOCK_TYPE

Enumerator
PFS_TL_READ 
PFS_TL_READ_WITH_SHARED_LOCKS 
PFS_TL_READ_HIGH_PRIORITY 
PFS_TL_READ_NO_INSERT 
PFS_TL_WRITE_ALLOW_WRITE 
PFS_TL_WRITE_CONCURRENT_INSERT 
PFS_TL_WRITE_LOW_PRIORITY 
PFS_TL_WRITE 
PFS_TL_READ_EXTERNAL 
PFS_TL_WRITE_EXTERNAL 
PFS_TL_NONE 

Function Documentation

◆ PFS_connection_all_statement_visitor()

PFS_connection_all_statement_visitor::PFS_connection_all_statement_visitor ( )

Constructor.

Instance wait visitor.

◆ PFS_connection_all_wait_visitor()

PFS_connection_all_wait_visitor::PFS_connection_all_wait_visitor ( )

Constructor.

◆ PFS_connection_error_visitor()

PFS_connection_error_visitor::PFS_connection_error_visitor ( PFS_error_class klass,
int  index 
)

Constructor.

◆ PFS_connection_memory_visitor()

PFS_connection_memory_visitor::PFS_connection_memory_visitor ( PFS_memory_class klass)

Constructor.

◆ PFS_connection_stage_visitor()

PFS_connection_stage_visitor::PFS_connection_stage_visitor ( PFS_stage_class klass)

Constructor.

◆ PFS_connection_stat_visitor()

PFS_connection_stat_visitor::PFS_connection_stat_visitor ( )

Constructor.

◆ PFS_connection_statement_visitor()

PFS_connection_statement_visitor::PFS_connection_statement_visitor ( PFS_statement_class klass)

Constructor.

◆ PFS_connection_status_visitor()

PFS_connection_status_visitor::PFS_connection_status_visitor ( System_status_var status_vars)

Constructor.

◆ PFS_connection_transaction_visitor()

PFS_connection_transaction_visitor::PFS_connection_transaction_visitor ( PFS_transaction_class klass)

Constructor.

◆ PFS_connection_wait_visitor()

PFS_connection_wait_visitor::PFS_connection_wait_visitor ( PFS_instr_class klass)

Constructor.

Connection wait visitor.

◆ PFS_index_io_stat_visitor()

PFS_index_io_stat_visitor::PFS_index_io_stat_visitor ( )

Index I/O stat visitor.

◆ PFS_instance_file_io_stat_visitor()

PFS_instance_file_io_stat_visitor::PFS_instance_file_io_stat_visitor ( )

◆ PFS_instance_socket_io_stat_visitor()

PFS_instance_socket_io_stat_visitor::PFS_instance_socket_io_stat_visitor ( )

◆ PFS_instance_wait_visitor()

PFS_instance_wait_visitor::PFS_instance_wait_visitor ( )

◆ PFS_object_wait_visitor()

PFS_object_wait_visitor::PFS_object_wait_visitor ( )

Table I/O wait visitor.

◆ PFS_table_io_stat_visitor()

PFS_table_io_stat_visitor::PFS_table_io_stat_visitor ( )

Table I/O stat visitor.

◆ PFS_table_io_wait_visitor()

PFS_table_io_wait_visitor::PFS_table_io_wait_visitor ( )

◆ PFS_table_lock_stat_visitor()

PFS_table_lock_stat_visitor::PFS_table_lock_stat_visitor ( )

Table lock stat visitor.

◆ PFS_table_lock_wait_visitor()

PFS_table_lock_wait_visitor::PFS_table_lock_wait_visitor ( )

Table lock wait visitor.

◆ ~PFS_connection_all_statement_visitor()

PFS_connection_all_statement_visitor::~PFS_connection_all_statement_visitor ( )
virtual

◆ ~PFS_connection_all_wait_visitor()

PFS_connection_all_wait_visitor::~PFS_connection_all_wait_visitor ( )
virtual

◆ ~PFS_connection_error_visitor()

PFS_connection_error_visitor::~PFS_connection_error_visitor ( )
virtual

◆ ~PFS_connection_memory_visitor()

PFS_connection_memory_visitor::~PFS_connection_memory_visitor ( )
virtual

◆ ~PFS_connection_stage_visitor()

PFS_connection_stage_visitor::~PFS_connection_stage_visitor ( )
virtual

◆ ~PFS_connection_stat_visitor()

PFS_connection_stat_visitor::~PFS_connection_stat_visitor ( )
virtual

◆ ~PFS_connection_statement_visitor()

PFS_connection_statement_visitor::~PFS_connection_statement_visitor ( )
virtual

◆ ~PFS_connection_status_visitor()

PFS_connection_status_visitor::~PFS_connection_status_visitor ( )
virtual

◆ ~PFS_connection_transaction_visitor()

PFS_connection_transaction_visitor::~PFS_connection_transaction_visitor ( )
virtual

◆ ~PFS_connection_wait_visitor()

PFS_connection_wait_visitor::~PFS_connection_wait_visitor ( )
virtual

◆ ~PFS_index_io_stat_visitor()

PFS_index_io_stat_visitor::~PFS_index_io_stat_visitor ( )
virtual

◆ ~PFS_instance_file_io_stat_visitor()

PFS_instance_file_io_stat_visitor::~PFS_instance_file_io_stat_visitor ( )
virtual

◆ ~PFS_instance_socket_io_stat_visitor()

PFS_instance_socket_io_stat_visitor::~PFS_instance_socket_io_stat_visitor ( )
virtual

◆ ~PFS_instance_wait_visitor()

PFS_instance_wait_visitor::~PFS_instance_wait_visitor ( )
virtual

◆ ~PFS_object_wait_visitor()

PFS_object_wait_visitor::~PFS_object_wait_visitor ( )
virtual

◆ ~PFS_table_io_stat_visitor()

PFS_table_io_stat_visitor::~PFS_table_io_stat_visitor ( )
virtual

◆ ~PFS_table_io_wait_visitor()

PFS_table_io_wait_visitor::~PFS_table_io_wait_visitor ( )
virtual

◆ ~PFS_table_lock_stat_visitor()

PFS_table_lock_stat_visitor::~PFS_table_lock_stat_visitor ( )
virtual

◆ ~PFS_table_lock_wait_visitor()

PFS_table_lock_wait_visitor::~PFS_table_lock_wait_visitor ( )
virtual

◆ account_hash_get_key()

static const uchar* account_hash_get_key ( const uchar entry,
size_t *  length 
)
static

◆ aggregate() [1/3]

void PFS_user::aggregate ( bool  alive)

◆ aggregate() [2/3]

void PFS_host::aggregate ( bool  alive)

◆ aggregate() [3/3]

void PFS_account::aggregate ( bool  alive,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_all_errors() [1/2]

void aggregate_all_errors ( PFS_error_stat from_array,
PFS_error_stat to_array 
)

◆ aggregate_all_errors() [2/2]

void aggregate_all_errors ( PFS_error_stat from_array,
PFS_error_stat to_array_1,
PFS_error_stat to_array_2 
)

◆ aggregate_all_event_names() [1/2]

void aggregate_all_event_names ( PFS_single_stat from_array,
PFS_single_stat to_array 
)

◆ aggregate_all_event_names() [2/2]

void aggregate_all_event_names ( PFS_single_stat from_array,
PFS_single_stat to_array_1,
PFS_single_stat to_array_2 
)

◆ aggregate_all_memory() [1/4]

void aggregate_all_memory ( bool  alive,
PFS_memory_safe_stat from_array,
PFS_memory_shared_stat to_array 
)

◆ aggregate_all_memory() [2/4]

void aggregate_all_memory ( bool  alive,
PFS_memory_shared_stat from_array,
PFS_memory_shared_stat to_array 
)

◆ aggregate_all_memory() [3/4]

void aggregate_all_memory ( bool  alive,
PFS_memory_safe_stat from_array,
PFS_memory_shared_stat to_array_1,
PFS_memory_shared_stat to_array_2 
)

◆ aggregate_all_memory() [4/4]

void aggregate_all_memory ( bool  alive,
PFS_memory_shared_stat from_array,
PFS_memory_shared_stat to_array_1,
PFS_memory_shared_stat to_array_2 
)

◆ aggregate_all_stages() [1/2]

void aggregate_all_stages ( PFS_stage_stat from_array,
PFS_stage_stat to_array 
)

◆ aggregate_all_stages() [2/2]

void aggregate_all_stages ( PFS_stage_stat from_array,
PFS_stage_stat to_array_1,
PFS_stage_stat to_array_2 
)

◆ aggregate_all_statements() [1/2]

void aggregate_all_statements ( PFS_statement_stat from_array,
PFS_statement_stat to_array 
)

◆ aggregate_all_statements() [2/2]

void aggregate_all_statements ( PFS_statement_stat from_array,
PFS_statement_stat to_array_1,
PFS_statement_stat to_array_2 
)

◆ aggregate_all_transactions() [1/2]

void aggregate_all_transactions ( PFS_transaction_stat from_array,
PFS_transaction_stat to_array 
)

◆ aggregate_all_transactions() [2/2]

void aggregate_all_transactions ( PFS_transaction_stat from_array,
PFS_transaction_stat to_array_1,
PFS_transaction_stat to_array_2 
)

◆ aggregate_errors() [1/3]

void PFS_user::aggregate_errors ( void  )

◆ aggregate_errors() [2/3]

void PFS_host::aggregate_errors ( void  )

◆ aggregate_errors() [3/3]

void PFS_account::aggregate_errors ( PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_io()

void PFS_table_share::aggregate_io ( void  )

◆ aggregate_lock()

void PFS_table_share::aggregate_lock ( void  )

◆ aggregate_memory() [1/3]

void PFS_user::aggregate_memory ( bool  alive)

◆ aggregate_memory() [2/3]

void PFS_host::aggregate_memory ( bool  alive)

◆ aggregate_memory() [3/3]

void PFS_account::aggregate_memory ( bool  alive,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_stages() [1/3]

void PFS_user::aggregate_stages ( void  )

◆ aggregate_stages() [2/3]

void PFS_host::aggregate_stages ( void  )

◆ aggregate_stages() [3/3]

void PFS_account::aggregate_stages ( PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_statements() [1/3]

void PFS_user::aggregate_statements ( void  )

◆ aggregate_statements() [2/3]

void PFS_host::aggregate_statements ( void  )

◆ aggregate_statements() [3/3]

void PFS_account::aggregate_statements ( PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_stats() [1/3]

void PFS_user::aggregate_stats ( void  )

◆ aggregate_stats() [2/3]

void PFS_host::aggregate_stats ( void  )

◆ aggregate_stats() [3/3]

void PFS_account::aggregate_stats ( PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_status() [1/3]

void PFS_user::aggregate_status ( void  )

◆ aggregate_status() [2/3]

void PFS_host::aggregate_status ( void  )

◆ aggregate_status() [3/3]

void PFS_account::aggregate_status ( PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread()

void aggregate_thread ( PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread_errors()

void aggregate_thread_errors ( PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread_memory()

void aggregate_thread_memory ( bool  alive,
PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread_stages()

void aggregate_thread_stages ( PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread_statements()

void aggregate_thread_statements ( PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread_stats()

static void aggregate_thread_stats ( PFS_thread ,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)
static

◆ aggregate_thread_status()

void aggregate_thread_status ( PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread_transactions()

void aggregate_thread_transactions ( PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_thread_waits()

void aggregate_thread_waits ( PFS_thread thread,
PFS_account safe_account,
PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_transactions() [1/3]

void PFS_user::aggregate_transactions ( void  )

◆ aggregate_transactions() [2/3]

void PFS_host::aggregate_transactions ( void  )

◆ aggregate_transactions() [3/3]

void PFS_account::aggregate_transactions ( PFS_user safe_user,
PFS_host safe_host 
)

◆ aggregate_waits() [1/3]

void PFS_user::aggregate_waits ( void  )

◆ aggregate_waits() [2/3]

void PFS_host::aggregate_waits ( void  )

◆ aggregate_waits() [3/3]

void PFS_account::aggregate_waits ( PFS_user safe_user,
PFS_host safe_host 
)

◆ carry_global_memory_stat_delta()

void carry_global_memory_stat_delta ( PFS_memory_stat_delta delta,
uint  index 
)

◆ carry_memory_stat_delta() [1/4]

void PFS_user::carry_memory_stat_delta ( PFS_memory_stat_delta delta,
uint  index 
)

◆ carry_memory_stat_delta() [2/4]

void PFS_host::carry_memory_stat_delta ( PFS_memory_stat_delta delta,
uint  index 
)

◆ carry_memory_stat_delta() [3/4]

void PFS_account::carry_memory_stat_delta ( PFS_memory_stat_delta delta,
uint  index 
)

◆ carry_memory_stat_delta() [4/4]

void PFS_thread::carry_memory_stat_delta ( PFS_memory_stat_delta delta,
uint  index 
)

◆ cleanup_account()

void cleanup_account ( void  )

Cleanup all the account buffers.

◆ cleanup_account_hash()

void cleanup_account_hash ( void  )

Cleanup the user hash.

◆ cleanup_file_class()

void cleanup_file_class ( void  )

Cleanup the file class buffers.

◆ cleanup_file_hash()

void cleanup_file_hash ( void  )

Cleanup the file name hash.

◆ cleanup_host()

void cleanup_host ( void  )

Cleanup all the host buffers.

◆ cleanup_host_hash()

void cleanup_host_hash ( void  )

Cleanup the host hash.

◆ cleanup_instruments()

void cleanup_instruments ( void  )

Cleanup all the instruments buffers.

◆ cleanup_memory_class()

void cleanup_memory_class ( void  )

Cleanup the memory class buffers.

◆ cleanup_setup_actor()

void cleanup_setup_actor ( void  )

Cleanup all the setup actor buffers.

◆ cleanup_setup_actor_hash()

void cleanup_setup_actor_hash ( void  )

Cleanup the setup actor hash.

◆ cleanup_setup_object()

void cleanup_setup_object ( void  )

Cleanup all the setup object buffers.

◆ cleanup_setup_object_hash()

void cleanup_setup_object_hash ( void  )

Cleanup the setup objects hash.

◆ cleanup_socket_class()

void cleanup_socket_class ( void  )

Cleanup the socket class buffers.

◆ cleanup_stage_class()

void cleanup_stage_class ( void  )

Cleanup the stage class buffers.

◆ cleanup_statement_class()

void cleanup_statement_class ( void  )

Cleanup the statement class buffers.

◆ cleanup_sync_class()

void cleanup_sync_class ( void  )

Cleanup the instrument synch class buffers.

◆ cleanup_table_share()

void cleanup_table_share ( void  )

Cleanup the table share buffers.

◆ cleanup_table_share_hash()

void cleanup_table_share_hash ( void  )

Cleanup the table share hash table.

◆ cleanup_table_share_index_stat()

void cleanup_table_share_index_stat ( void  )

Cleanup the table stat buffers.

◆ cleanup_table_share_lock_stat()

void cleanup_table_share_lock_stat ( void  )

Cleanup the table stat buffers.

◆ cleanup_thread_class()

void cleanup_thread_class ( void  )

Cleanup the thread class buffers.

◆ cleanup_user()

void cleanup_user ( void  )

Cleanup all the user buffers.

◆ cleanup_user_hash()

void cleanup_user_hash ( void  )

Cleanup the user hash.

◆ clear_thread_account()

void clear_thread_account ( PFS_thread thread)

◆ compare_keys()

static int compare_keys ( PFS_table_share pfs,
const TABLE_SHARE share 
)
static

◆ configure_instr_class()

static void configure_instr_class ( PFS_instr_class entry)
static

Set user-defined configuration values for an instrument.

Compare class name to all configuration entries. In case of multiple matches, the longer specification wins. For example, the pattern 'ABC/DEF/GHI=ON' has precedence over 'ABC/DEF/%=OFF' regardless of position within the configuration file or command line.

Consecutive wildcards affect the count.

◆ create_cond()

PFS_cond * create_cond ( PFS_cond_class klass,
const void *  identity 
)

Create instrumentation for a condition instance.

Parameters
klassthe condition class
identitythe condition address
Returns
a condition instance, or NULL

◆ create_metadata_lock()

PFS_metadata_lock * create_metadata_lock ( void *  identity,
const MDL_key mdl_key,
opaque_mdl_type  mdl_type,
opaque_mdl_duration  mdl_duration,
opaque_mdl_status  mdl_status,
const char *  src_file,
uint  src_line 
)

◆ create_mutex()

PFS_mutex * create_mutex ( PFS_mutex_class klass,
const void *  identity 
)

Create instrumentation for a mutex instance.

Parameters
klassthe mutex class
identitythe mutex address
Returns
a mutex instance, or NULL

◆ create_rwlock()

PFS_rwlock * create_rwlock ( PFS_rwlock_class klass,
const void *  identity 
)

Create instrumentation for a rwlock instance.

Parameters
klassthe rwlock class
identitythe rwlock address
Returns
a rwlock instance, or NULL

◆ create_socket()

PFS_socket * create_socket ( PFS_socket_class klass,
const my_socket fd,
const struct sockaddr *  addr,
socklen_t  addr_len 
)

Create instrumentation for a socket instance.

Parameters
klassthe socket class
fdthe socket file descriptor
addrthe socket address
addr_lenthe socket address length
Returns
a socket instance, or NULL

◆ create_table()

PFS_table * create_table ( PFS_table_share share,
PFS_thread opening_thread,
const void *  identity 
)

Create instrumentation for a table instance.

Parameters
sharethe table share
opening_threadthe opening thread
identitythe table address
Returns
a table instance, or NULL

◆ create_table_share_index_stat()

PFS_table_share_index * create_table_share_index_stat ( const TABLE_SHARE server_share,
uint  server_index 
)

Create a table share index instrumentation.

Returns
table share index instrumentation, or NULL

◆ create_table_share_lock_stat()

PFS_table_share_lock * create_table_share_lock_stat ( )

Create a table share lock instrumentation.

Returns
table share lock instrumentation, or NULL

◆ create_thread()

PFS_thread * create_thread ( PFS_thread_class klass,
const void *  identity,
ulonglong  processlist_id 
)

Create instrumentation for a thread instance.

Parameters
klassthe thread class
identitythe thread address, or a value characteristic of this thread
processlist_idthe PROCESSLIST id, or 0 if unknown
Returns
a thread instance, or NULL

◆ delete_setup_actor()

int delete_setup_actor ( const String user,
const String host,
const String role 
)

◆ delete_setup_object()

int delete_setup_object ( enum_object_type  object_type,
const String schema,
const String object 
)

◆ destroy_cond()

void destroy_cond ( PFS_cond pfs)

Destroy instrumentation for a condition instance.

Parameters
pfsthe condition to destroy

◆ destroy_file()

void destroy_file ( PFS_thread thread,
PFS_file pfs 
)

Destroy instrumentation for a file instance.

Parameters
threadthe executing thread instrumentation
pfsthe file to destroy

◆ destroy_index_stats()

void PFS_table_share::destroy_index_stats ( )

Destroy table share index instrumentation.

◆ destroy_lock_stat()

void PFS_table_share::destroy_lock_stat ( )

Destroy a table share lock instrumentation.

◆ destroy_metadata_lock()

void destroy_metadata_lock ( PFS_metadata_lock pfs)

◆ destroy_mutex()

void destroy_mutex ( PFS_mutex pfs)

Destroy instrumentation for a mutex instance.

Parameters
pfsthe mutex to destroy

◆ destroy_rwlock()

void destroy_rwlock ( PFS_rwlock pfs)

Destroy instrumentation for a rwlock instance.

Parameters
pfsthe rwlock to destroy

◆ destroy_socket()

void destroy_socket ( PFS_socket pfs)

Destroy instrumentation for a socket instance.

Parameters
pfsthe socket to destroy

◆ destroy_table()

void destroy_table ( PFS_table pfs)

Destroy instrumentation for a table instance.

Parameters
pfsthe table to destroy

◆ destroy_thread()

void destroy_thread ( PFS_thread pfs)

Destroy instrumentation for a thread instance.

Parameters
pfsthe thread to destroy

◆ drop_table_share()

void drop_table_share ( PFS_thread thread,
bool  temporary,
const char *  schema_name,
uint  schema_name_length,
const char *  table_name,
uint  table_name_length 
)

Drop the instrumented table share associated with a table.

Parameters
threadThe running thread
temporaryTrue for TEMPORARY TABLE
schema_nameThe table schema name
schema_name_lengthThe table schema name length
table_nameThe table name
table_name_lengthThe table name length

◆ fct_reset_cond_waits()

static void fct_reset_cond_waits ( PFS_cond pfs)
static

◆ fct_reset_file_io()

static void fct_reset_file_io ( PFS_file pfs)
static

◆ fct_reset_file_waits()

static void fct_reset_file_waits ( PFS_file pfs)
static

◆ fct_reset_metadata_source_file_pointers()

static void fct_reset_metadata_source_file_pointers ( PFS_metadata_lock pfs)
static

◆ fct_reset_mutex_waits()

static void fct_reset_mutex_waits ( PFS_mutex pfs)
static

◆ fct_reset_rwlock_waits()

static void fct_reset_rwlock_waits ( PFS_rwlock pfs)
static

◆ fct_reset_socket_io()

static void fct_reset_socket_io ( PFS_socket pfs)
static

◆ fct_reset_socket_waits()

static void fct_reset_socket_waits ( PFS_socket pfs)
static

◆ fct_reset_source_file_pointers()

static void fct_reset_source_file_pointers ( PFS_thread pfs_thread)
static

For each thread, clear the source file pointers from all waits, stages, statements and transaction events.

◆ fct_update_cond_derived_flags()

static void fct_update_cond_derived_flags ( PFS_cond pfs)
static

◆ fct_update_file_derived_flags()

static void fct_update_file_derived_flags ( PFS_file pfs)
static

◆ fct_update_metadata_derived_flags()

static void fct_update_metadata_derived_flags ( PFS_metadata_lock pfs)
static

◆ fct_update_mutex_derived_flags()

static void fct_update_mutex_derived_flags ( PFS_mutex pfs)
static

◆ fct_update_rwlock_derived_flags()

static void fct_update_rwlock_derived_flags ( PFS_rwlock pfs)
static

◆ fct_update_socket_derived_flags()

static void fct_update_socket_derived_flags ( PFS_socket pfs)
static

◆ fct_update_table_derived_flags()

static void fct_update_table_derived_flags ( PFS_table pfs)
static

◆ fct_update_thread_derived_flags()

static void fct_update_thread_derived_flags ( PFS_thread pfs)
static

◆ filename_hash_get_key()

static const uchar* filename_hash_get_key ( const uchar entry,
size_t *  length 
)
static

Get hash table key for instrumented files.

◆ find_and_rename_file()

void find_and_rename_file ( PFS_thread thread,
const char *  old_filename,
uint  old_len,
const char *  new_filename,
uint  new_len 
)

Find a file instrumentation instance by name, and rename it.

Parameters
threadthe executing instrumented thread
old_filenamethe file to be renamed
old_lenthe length in bytes of the old filename
new_filenamethe new file name
new_lenthe length in bytes of the new filename

◆ find_cond_class()

PFS_cond_class * find_cond_class ( PFS_sync_key  key)

Find a condition instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_error_class()

PFS_error_class * find_error_class ( uint  index)

◆ find_file_class()

PFS_file_class * find_file_class ( PFS_file_key  key)

Find a file instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_idle_class()

PFS_instr_class * find_idle_class ( uint  index)

◆ find_index_stat()

PFS_table_share_index * PFS_table_share::find_index_stat ( uint  index) const

Find an existing table share index instrumentation.

Returns
a table share index

◆ find_lock_stat()

PFS_table_share_lock * PFS_table_share::find_lock_stat ( ) const

Find an existing table share lock instrumentation.

Returns
a table share lock.

◆ find_memory_class()

PFS_memory_class * find_memory_class ( PFS_memory_key  key)

Find a memory instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_metadata_class()

PFS_instr_class * find_metadata_class ( uint  index)

◆ find_mutex_class()

PFS_mutex_class * find_mutex_class ( PFS_sync_key  key)

Find a mutex instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_or_create_account()

PFS_account * find_or_create_account ( PFS_thread thread,
const char *  username,
uint  username_length,
const char *  hostname,
uint  hostname_length 
)

◆ find_or_create_file()

PFS_file * find_or_create_file ( PFS_thread thread,
PFS_file_class klass,
const char *  filename,
uint  len,
bool  create 
)

Find or create instrumentation for a file instance by file name.

Parameters
threadthe executing instrumented thread
klassthe file class
filenamethe file name
lenthe length in bytes of filename
createcreate a file instance if none found
Returns
a file instance, or NULL

◆ find_or_create_host()

PFS_host * find_or_create_host ( PFS_thread thread,
const char *  hostname,
uint  hostname_length 
)

◆ find_or_create_index_stat()

PFS_table_share_index * PFS_table_share::find_or_create_index_stat ( const TABLE_SHARE server_share,
uint  index 
)

Find or create a table share index instrumentation.

Parameters
server_sharethe server TABLE_SHARE structure
indexthe index
Returns
a table share index, or NULL

◆ find_or_create_lock_stat()

PFS_table_share_lock * PFS_table_share::find_or_create_lock_stat ( )

Find or create a table share lock instrumentation.

Returns
a table share lock, or NULL.

◆ find_or_create_table_share()

PFS_table_share * find_or_create_table_share ( PFS_thread thread,
bool  temporary,
const TABLE_SHARE share 
)

Find or create a table share instrumentation.

Parameters
threadthe executing instrumented thread
temporarytrue for TEMPORARY TABLE
sharetable share
Returns
a table share, or NULL

◆ find_or_create_user()

PFS_user * find_or_create_user ( PFS_thread thread,
const char *  username,
uint  username_length 
)

◆ find_rwlock_class()

PFS_rwlock_class * find_rwlock_class ( PFS_sync_key  key)

Find a rwlock instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_socket_class()

PFS_socket_class * find_socket_class ( PFS_socket_key  key)

Find a socket instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_stage_class()

PFS_stage_class * find_stage_class ( PFS_stage_key  key)

Find a stage instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_statement_class()

PFS_statement_class * find_statement_class ( PFS_stage_key  key)

Find a statement instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_table_class()

PFS_instr_class * find_table_class ( uint  index)

◆ find_thread_by_internal_id()

PFS_thread * find_thread_by_internal_id ( ulonglong  thread_id)

Find a PFS thread given an internal thread id.

Parameters
thread_idinternal thread id
Returns
pfs pointer if found, else NULL

◆ find_thread_by_processlist_id()

PFS_thread * find_thread_by_processlist_id ( ulonglong  processlist_id)

Find a PFS thread given a processlist id.

Parameters
processlist_idPROCESSLIST_ID
Returns
pfs pointer if found, else NULL

◆ find_thread_class()

PFS_thread_class * find_thread_class ( PFS_sync_key  key)

Find a thread instrumentation class by key.

Parameters
keythe instrument key
Returns
the instrument class, or NULL

◆ find_transaction_class()

PFS_transaction_class * find_transaction_class ( uint  index)

◆ get_account_hash_pins()

static LF_PINS* get_account_hash_pins ( PFS_thread thread)
static

◆ get_current_thread()

PFS_thread * PFS_thread::get_current_thread ( void  )
static

◆ get_filename_hash_pins()

static LF_PINS* get_filename_hash_pins ( PFS_thread thread)
static

Get the hash pins for filename_hash.

Parameters
threadThe running thread.
Returns
The LF_HASH pins for the thread.

◆ get_host_hash_pins()

static LF_PINS* get_host_hash_pins ( PFS_thread thread)
static

◆ get_pfs_from_THD()

static PFS_thread* get_pfs_from_THD ( THD thd)
static

◆ get_setup_actor_hash_pins()

static LF_PINS* get_setup_actor_hash_pins ( PFS_thread thread)
static

◆ get_setup_object_hash_pins()

static LF_PINS* get_setup_object_hash_pins ( PFS_thread thread)
static

◆ get_table_share_hash_pins()

static LF_PINS* get_table_share_hash_pins ( PFS_thread thread)
static

Get the hash pins for.

See also
table_share_hash.
Parameters
threadThe running thread.
Returns
The LF_HASH pins for the thread.

◆ get_user_hash_pins()

static LF_PINS* get_user_hash_pins ( PFS_thread thread)
static

◆ gtid_monitoring_getsystime()

ulonglong gtid_monitoring_getsystime ( )

Get current time for GTID monitoring.

Returns
my_getsystime() when PFS monitoring is enabled.
0 when PFS monitoring is disabled.

◆ host_hash_get_key()

static const uchar* host_hash_get_key ( const uchar entry,
size_t *  length 
)
static

◆ init_account()

int init_account ( const PFS_global_param param)

Initialize the user buffers.

Parameters
paramsizing parameters
Returns
0 on success

◆ init_account_hash()

int init_account_hash ( const PFS_global_param param)

Initialize the user hash.

Returns
0 on success

◆ init_event_name_sizing()

void init_event_name_sizing ( const PFS_global_param param)

◆ init_file_class()

int init_file_class ( uint  file_class_sizing)

Initialize the file class buffer.

Parameters
file_class_sizingmax number of file class
Returns
0 on success

◆ init_file_hash()

int init_file_hash ( const PFS_global_param param)

Initialize the file name hash.

Returns
0 on success

◆ init_host()

int init_host ( const PFS_global_param param)

Initialize the host buffers.

Parameters
paramsizing parameters
Returns
0 on success

◆ init_host_hash()

int init_host_hash ( const PFS_global_param param)

Initialize the host hash.

Returns
0 on success

◆ init_instr_class()

static void init_instr_class ( PFS_instr_class klass,
const char *  name,
uint  name_length,
int  flags,
int  volatility,
const char *  documentation,
PFS_class_type  class_type 
)
static

◆ init_instruments()

int init_instruments ( const PFS_global_param param)

Initialize all the instruments instance buffers.

Parameters
paramsizing parameters
Returns
0 on success

◆ init_memory_class()

int init_memory_class ( uint  memory_class_sizing)

Initialize the memory class buffer.

Parameters
memory_class_sizingmax number of memory class
Returns
0 on success

◆ init_setup_actor()

int init_setup_actor ( const PFS_global_param param)

Initialize the setup actor buffers.

Parameters
paramsizing parameters
Returns
0 on success

◆ init_setup_actor_hash()

int init_setup_actor_hash ( const PFS_global_param param)

Initialize the setup actor hash.

Returns
0 on success

◆ init_setup_object()

int init_setup_object ( const PFS_global_param param)

Initialize the setup object buffers.

Parameters
paramsizing parameters
Returns
0 on success

◆ init_setup_object_hash()

int init_setup_object_hash ( const PFS_global_param param)

Initialize the setup objects hash.

Returns
0 on success

◆ init_socket_class()

int init_socket_class ( uint  socket_class_sizing)

Initialize the socket class buffer.

Parameters
socket_class_sizingmax number of socket class
Returns
0 on success

◆ init_stage_class()

int init_stage_class ( uint  stage_class_sizing)

Initialize the stage class buffer.

Parameters
stage_class_sizingmax number of stage class
Returns
0 on success

◆ init_statement_class()

int init_statement_class ( uint  statement_class_sizing)

Initialize the statement class buffer.

Parameters
statement_class_sizingmax number of statement class
Returns
0 on success

◆ init_sync_class()

int init_sync_class ( uint  mutex_class_sizing,
uint  rwlock_class_sizing,
uint  cond_class_sizing 
)

Initialize the instrument synch class buffers.

Parameters
mutex_class_sizingmax number of mutex class
rwlock_class_sizingmax number of rwlock class
cond_class_sizingmax number of condition class
Returns
0 on success

◆ init_table_share()

int init_table_share ( uint  table_share_sizing)

Initialize the table share buffer.

Parameters
table_share_sizingmax number of table share
Returns
0 on success

◆ init_table_share_hash()

int init_table_share_hash ( const PFS_global_param param)

Initialize the table share hash table.

◆ init_table_share_index_stat()

int init_table_share_index_stat ( uint  index_stat_sizing)

Initialize table index stat buffer.

Parameters
index_stat_sizingmax number of index statistics
Returns
0 on success

◆ init_table_share_lock_stat()

int init_table_share_lock_stat ( uint  table_stat_sizing)

Initialize the table lock stat buffer.

Parameters
table_stat_sizingmax number of table lock statistics
Returns
0 on success

◆ init_thread_class()

int init_thread_class ( uint  thread_class_sizing)

Initialize the thread class buffer.

Parameters
thread_class_sizingmax number of thread class
Returns
0 on success

◆ init_user()

int init_user ( const PFS_global_param param)

Initialize the user buffers.

Parameters
paramsizing parameters
Returns
0 on success

◆ init_user_hash()

int init_user_hash ( const PFS_global_param param)

Initialize the user hash.

Returns
0 on success

◆ insert_setup_actor()

int insert_setup_actor ( const String user,
const String host,
const String role,
bool  enabled,
bool  history 
)

◆ insert_setup_object()

int insert_setup_object ( enum_object_type  object_type,
const String schema,
const String object,
bool  enabled,
bool  timed 
)

◆ lookup_setup_actor()

void lookup_setup_actor ( PFS_thread thread,
const char *  user,
uint  user_length,
const char *  host,
uint  host_length,
bool enabled,
bool history 
)

◆ lookup_setup_object()

void lookup_setup_object ( PFS_thread thread,
enum_object_type  object_type,
const char *  schema_name,
int  schema_name_length,
const char *  object_name,
int  object_name_length,
bool enabled,
bool timed 
)

◆ memory_full_aggregate() [1/2]

template<typename F , typename T >
void memory_full_aggregate ( const F *  from,
T *  stat 
)

◆ memory_full_aggregate() [2/2]

template<typename F , typename T >
void memory_full_aggregate ( const F *  from,
T *  stat1,
T *  stat2 
)

◆ memory_partial_aggregate() [1/2]

template<typename F , typename T >
void memory_partial_aggregate ( F *  from,
T *  stat 
)

◆ memory_partial_aggregate() [2/2]

template<typename F , typename T >
void memory_partial_aggregate ( F *  from,
T *  stat1,
T *  stat2 
)

◆ pfs_unload_plugin_ref_count()

std::atomic<uint32> pfs_unload_plugin_ref_count ( )

Global performance schema reference count for plugin and component events.

Incremented when a shared library is being unloaded, decremented when the performance schema is finished processing the event.

◆ purge_account()

static void purge_account ( PFS_thread thread,
PFS_account account 
)
static

◆ purge_all_account()

void purge_all_account ( void  )

Purge non connected accounts, reset stats of connected account.

◆ purge_all_host()

void purge_all_host ( void  )

Purge non connected hosts, reset stats of connected hosts.

◆ purge_all_user()

void purge_all_user ( void  )

Purge non connected users, reset stats of connected users.

◆ purge_host()

static void purge_host ( PFS_thread thread,
PFS_host host 
)
static

◆ purge_user()

static void purge_user ( PFS_thread thread,
PFS_user user 
)
static

◆ rebase_memory_stats() [1/4]

void PFS_user::rebase_memory_stats ( )

Reset all memory statistics.

◆ rebase_memory_stats() [2/4]

void PFS_host::rebase_memory_stats ( )

Reset all memory statistics.

◆ rebase_memory_stats() [3/4]

void PFS_account::rebase_memory_stats ( )

Reset all memory statistics.

◆ rebase_memory_stats() [4/4]

void PFS_thread::rebase_memory_stats ( )

Reset all memory statistics.

◆ refresh_setup_object_flags()

void PFS_table_share::refresh_setup_object_flags ( PFS_thread thread)

◆ register_cond_class()

PFS_sync_key register_cond_class ( const char *  name,
uint  name_length,
PSI_cond_info info 
)

Register a condition instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a condition instrumentation key

◆ register_file_class()

PFS_file_key register_file_class ( const char *  name,
uint  name_length,
PSI_file_info info 
)

Register a file instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a file instrumentation key

◆ register_global_classes()

void register_global_classes ( )

◆ register_memory_class()

PFS_memory_key register_memory_class ( const char *  name,
uint  name_length,
PSI_memory_info info 
)

Register a memory instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a memory instrumentation key

◆ register_mutex_class()

PFS_sync_key register_mutex_class ( const char *  name,
uint  name_length,
PSI_mutex_info info 
)

Register a mutex instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a mutex instrumentation key

◆ register_rwlock_class()

PFS_sync_key register_rwlock_class ( const char *  name,
uint  name_length,
PSI_rwlock_info info 
)

Register a rwlock instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a rwlock instrumentation key

◆ register_socket_class()

PFS_socket_key register_socket_class ( const char *  name,
uint  name_length,
PSI_socket_info info 
)

Register a socket instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a socket instrumentation key

◆ register_stage_class()

PFS_stage_key register_stage_class ( const char *  name,
uint  prefix_length,
uint  name_length,
PSI_stage_info info 
)

Register a stage instrumentation metadata.

Parameters
namethe instrumented name
prefix_lengthlength in bytes of the name prefix
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a stage instrumentation key

◆ register_statement_class()

PFS_statement_key register_statement_class ( const char *  name,
uint  name_length,
PSI_statement_info info 
)

Register a statement instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a statement instrumentation key

◆ register_thread_class()

PFS_thread_key register_thread_class ( const char *  name,
uint  name_length,
PSI_thread_info info 
)

Register a thread instrumentation metadata.

Parameters
namethe instrumented name
name_lengthlength in bytes of name
infothe instrumentation properties
Returns
a thread instrumentation key

◆ release() [1/3]

void PFS_user::release ( void  )

◆ release() [2/3]

void PFS_host::release ( void  )

◆ release() [3/3]

void PFS_account::release ( void  )

◆ release_file()

void release_file ( PFS_file pfs)

Release instrumentation for a file instance.

Parameters
pfsthe file to release

◆ release_table_share()

void release_table_share ( PFS_table_share pfs)

◆ release_table_share_index_stat()

void release_table_share_index_stat ( PFS_table_share_index pfs)

Release a table share index instrumentation.

◆ release_table_share_lock_stat()

void release_table_share_lock_stat ( PFS_table_share_lock pfs)

Release a table share lock instrumentation.

◆ reset_cond_waits_by_instance()

static void reset_cond_waits_by_instance ( void  )
static

◆ reset_errors_stats()

void PFS_connection_slice::reset_errors_stats ( )

Reset all errors statistics.

◆ reset_events_waits_by_class()

void reset_events_waits_by_class ( )

Reset the wait statistics per instrument class.

◆ reset_events_waits_by_instance()

void reset_events_waits_by_instance ( void  )

Reset the wait statistics per object instance.

◆ reset_file_class_io()

void reset_file_class_io ( void  )

Reset the I/O statistics per file class.

◆ reset_file_instance_io()

void reset_file_instance_io ( void  )

Reset the I/O statistics per file instance.

◆ reset_file_waits_by_instance()

static void reset_file_waits_by_instance ( void  )
static

◆ reset_histogram_global()

void reset_histogram_global ( )

◆ reset_mutex_waits_by_instance()

static void reset_mutex_waits_by_instance ( void  )
static

◆ reset_rwlock_waits_by_instance()

static void reset_rwlock_waits_by_instance ( void  )
static

◆ reset_session_connect_attrs()

void PFS_thread::reset_session_connect_attrs ( )

Reset session connect attributes.

◆ reset_setup_actor()

int reset_setup_actor ( )

◆ reset_setup_object()

int reset_setup_object ( )

◆ reset_socket_class_io()

void reset_socket_class_io ( void  )

Reset the I/O statistics per socket class.

◆ reset_socket_instance_io()

void reset_socket_instance_io ( void  )

Reset the I/O statistics per socket instance.

◆ reset_socket_waits_by_instance()

static void reset_socket_waits_by_instance ( void  )
static

◆ reset_source_file_pointers()

void reset_source_file_pointers ( )

Clear the source file pointers from all waits, stages, statements and transaction events.

Clear source file pointers for all statements, stages, waits and transactions.

This function is called whenever a plugin or component is unloaded.

The Performance Schema stores the source file and line number for wait, stage, statement, transaction and metadata lock events. The source file string pointer is taken from the FILE macro. Source file pointers that reference files within a shared library become invalid when the shared library is unloaded, therefore all source file pointers are set to NULL whenever a plugin or component is unloaded.

◆ reset_stages_stats()

void PFS_connection_slice::reset_stages_stats ( )

Reset all stages statistics.

◆ reset_statements_stats()

void PFS_connection_slice::reset_statements_stats ( )

Reset all statements statistics.

◆ reset_transactions_stats()

void PFS_connection_slice::reset_transactions_stats ( )

Reset all transactions statistics.

◆ reset_waits_stats()

void PFS_connection_slice::reset_waits_stats ( )

Reset all wait statistics.

◆ safe_aggregate_io()

void PFS_table::safe_aggregate_io ( const TABLE_SHARE optional_server_share,
PFS_table_stat stat,
PFS_table_share safe_share 
)
staticprivate

◆ safe_aggregate_lock()

void PFS_table::safe_aggregate_lock ( PFS_table_stat stat,
PFS_table_share safe_share 
)
staticprivate

◆ sanitize_account()

PFS_account * sanitize_account ( PFS_account unsafe)

◆ sanitize_cond()

PFS_cond * sanitize_cond ( PFS_cond unsafe)

◆ sanitize_cond_class()

PFS_cond_class * sanitize_cond_class ( PFS_cond_class unsafe)

◆ sanitize_error_class() [1/2]

PFS_error_class* sanitize_error_class ( PFS_instr_class unsafe)

◆ sanitize_error_class() [2/2]

PFS_error_class* sanitize_error_class ( PFS_error_class unsafe)

◆ sanitize_file()

PFS_file * sanitize_file ( PFS_file unsafe)

◆ sanitize_file_class()

PFS_file_class * sanitize_file_class ( PFS_file_class unsafe)

◆ sanitize_host()

PFS_host * sanitize_host ( PFS_host unsafe)

◆ sanitize_idle_class()

PFS_instr_class * sanitize_idle_class ( PFS_instr_class unsafe)

◆ sanitize_index_count()

uint sanitize_index_count ( uint  count)
inline

◆ sanitize_memory_class()

PFS_memory_class * sanitize_memory_class ( PFS_memory_class unsafe)

◆ sanitize_metadata_class()

PFS_instr_class * sanitize_metadata_class ( PFS_instr_class unsafe)

◆ sanitize_metadata_lock()

PFS_metadata_lock * sanitize_metadata_lock ( PFS_metadata_lock unsafe)

◆ sanitize_mutex()

PFS_mutex * sanitize_mutex ( PFS_mutex unsafe)

◆ sanitize_mutex_class()

PFS_mutex_class * sanitize_mutex_class ( PFS_mutex_class unsafe)

◆ sanitize_rwlock()

PFS_rwlock * sanitize_rwlock ( PFS_rwlock unsafe)

◆ sanitize_rwlock_class()

PFS_rwlock_class * sanitize_rwlock_class ( PFS_rwlock_class unsafe)

◆ sanitize_socket()

PFS_socket * sanitize_socket ( PFS_socket unsafe)

◆ sanitize_socket_class()

PFS_socket_class * sanitize_socket_class ( PFS_socket_class unsafe)

◆ sanitize_stage_class()

PFS_stage_class * sanitize_stage_class ( PFS_stage_class unsafe)

◆ sanitize_statement_class()

PFS_statement_class * sanitize_statement_class ( PFS_statement_class unsafe)

◆ sanitize_table_class()

PFS_instr_class * sanitize_table_class ( PFS_instr_class unsafe)

◆ sanitize_table_share()

PFS_table_share * sanitize_table_share ( PFS_table_share unsafe)

Sanitize an unsafe table_share pointer.

Parameters
unsafeThe possibly corrupt pointer.
Returns
A valid table_safe_pointer, or NULL.

◆ sanitize_thread()

PFS_thread * sanitize_thread ( PFS_thread unsafe)

Sanitize a PFS_thread pointer.

Validate that the PFS_thread is part of thread_array. Sanitizing data is required when the data can be damaged with expected race conditions, for example involving EVENTS_WAITS_HISTORY_LONG.

Parameters
unsafethe pointer to sanitize
Returns
a valid pointer, or NULL

◆ sanitize_thread_class()

PFS_thread_class * sanitize_thread_class ( PFS_thread_class unsafe)

◆ sanitize_transaction_class()

PFS_transaction_class * sanitize_transaction_class ( PFS_transaction_class unsafe)

◆ sanitize_user()

PFS_user * sanitize_user ( PFS_user unsafe)

◆ sanitized_aggregate()

void PFS_table::sanitized_aggregate ( void  )

Aggregate this table handle statistics to the parents.

This method is safe to call on handles not owned by the calling code.

See also
aggregate
sanitized_aggregate_io
sanitized_aggregate_lock

◆ sanitized_aggregate_io()

void PFS_table::sanitized_aggregate_io ( void  )

Aggregate this table handle I/O statistics to the parents.

This method is safe to call on handles not owned by the calling code.

◆ sanitized_aggregate_lock()

void PFS_table::sanitized_aggregate_lock ( void  )

Aggregate this table handle lock statistics to the parents.

This method is safe to call on handles not owned by the calling code.

◆ set_account_key()

static void set_account_key ( PFS_account_key key,
const char *  user,
uint  user_length,
const char *  host,
uint  host_length 
)
static

◆ set_history_derived_flags()

void PFS_thread::set_history_derived_flags ( )

◆ set_host_key()

static void set_host_key ( PFS_host_key key,
const char *  host,
uint  host_length 
)
static

◆ set_setup_actor_key()

static void set_setup_actor_key ( PFS_setup_actor_key key,
const char *  user,
uint  user_length,
const char *  host,
uint  host_length,
const char *  role,
uint  role_length 
)
static

◆ set_setup_object_key()

static void set_setup_object_key ( PFS_setup_object_key key,
enum_object_type  object_type,
const char *  schema,
uint  schema_length,
const char *  object,
uint  object_length 
)
static

◆ set_table_share_key()

static void set_table_share_key ( PFS_table_share_key key,
bool  temporary,
const char *  schema_name,
size_t  schema_name_length,
const char *  table_name,
size_t  table_name_length 
)
static

Set a table share hash key.

Parameters
[out]keyThe key to populate.
temporaryTrue for TEMPORARY TABLE.
schema_nameThe table schema name.
schema_name_lengthThe table schema name length.
table_nameThe table name.
table_name_lengthThe table name length.

◆ set_thread_account()

void set_thread_account ( PFS_thread thread)

◆ set_user_key()

static void set_user_key ( PFS_user_key key,
const char *  user,
uint  user_length 
)
static

◆ setup_actor_count()

long setup_actor_count ( )

◆ setup_actor_hash_get_key()

static const uchar* setup_actor_hash_get_key ( const uchar entry,
size_t *  length 
)
static

◆ setup_object_count()

long setup_object_count ( )

◆ setup_object_hash_get_key()

static const uchar* setup_object_hash_get_key ( const uchar entry,
size_t *  length 
)
static

◆ sum()

void PFS_table_share::sum ( PFS_single_stat result,
uint  key_count 
)

◆ sum_io()

void PFS_table_share::sum_io ( PFS_single_stat result,
uint  key_count 
)

◆ sum_lock()

void PFS_table_share::sum_lock ( PFS_single_stat result)

◆ table_share_hash_get_key()

static const uchar* table_share_hash_get_key ( const uchar entry,
size_t *  length 
)
static

get_key function for table_share_hash.

◆ update_accounts_derived_flags()

void update_accounts_derived_flags ( PFS_thread thread)

◆ update_cond_derived_flags()

void update_cond_derived_flags ( )

Update derived flags for all condition instances.

◆ update_file_derived_flags()

void update_file_derived_flags ( )

Update derived flags for all file handles.

◆ update_instruments_derived_flags()

void update_instruments_derived_flags ( )

Update derived flags for all instruments.

◆ update_metadata_derived_flags()

void update_metadata_derived_flags ( )

Update derived flags for all metadata instances.

◆ update_mutex_derived_flags()

void update_mutex_derived_flags ( )

Update derived flags for all mutex instances.

◆ update_program_share_derived_flags()

void update_program_share_derived_flags ( PFS_thread thread)

Update derived flags for all stored procedure shares.

◆ update_rwlock_derived_flags()

void update_rwlock_derived_flags ( )

Update derived flags for all rwlock instances.

◆ update_setup_actors_derived_flags()

int update_setup_actors_derived_flags ( )

Update derived flags for all setup_actors.

◆ update_socket_derived_flags()

void update_socket_derived_flags ( )

Update derived flags for all socket instances.

◆ update_table_derived_flags()

void update_table_derived_flags ( )

Update derived flags for all table handles.

◆ update_table_share_derived_flags()

void update_table_share_derived_flags ( PFS_thread thread)

Update derived flags for all table shares.

◆ update_thread_derived_flags()

void update_thread_derived_flags ( )

Update derived flags for all thread instances.

◆ user_hash_get_key()

static const uchar* user_hash_get_key ( const uchar entry,
size_t *  length 
)
static

◆ visit_account() [1/11]

void PFS_connection_iterator::visit_account ( PFS_account account,
bool  with_threads,
bool  with_THDs,
PFS_connection_visitor visitor 
)
static

Visit all connections of a user+host.

Parameters
accountthe user+host to visit.
with_threadswhen true, visit also all related threads.
with_THDswhen true, visit also all related threads THD.
visitorthe visitor to call

◆ visit_account() [2/11]

void PFS_connection_wait_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [3/11]

void PFS_connection_all_wait_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [4/11]

void PFS_connection_stage_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [5/11]

void PFS_connection_statement_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [6/11]

void PFS_connection_all_statement_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [7/11]

void PFS_connection_transaction_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [8/11]

void PFS_connection_error_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [9/11]

void PFS_connection_stat_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [10/11]

void PFS_connection_memory_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_account() [11/11]

void PFS_connection_status_visitor::visit_account ( PFS_account )
virtual

Visit all connections of a user+host.

Reimplemented from PFS_connection_visitor.

◆ visit_all() [1/2]

void PFS_instance_iterator::visit_all ( PFS_instance_visitor visitor)
static

◆ visit_all() [2/2]

void PFS_object_iterator::visit_all ( PFS_object_visitor visitor)
static

Visit all objects.

Object iterator.

◆ visit_all_cond()

void PFS_instance_iterator::visit_all_cond ( PFS_instance_visitor visitor)
static

◆ visit_all_cond_classes()

void PFS_instance_iterator::visit_all_cond_classes ( PFS_instance_visitor visitor)
static

◆ visit_all_cond_instances()

void PFS_instance_iterator::visit_all_cond_instances ( PFS_instance_visitor visitor)
static

◆ visit_all_file()

void PFS_instance_iterator::visit_all_file ( PFS_instance_visitor visitor)
static

◆ visit_all_file_classes()

void PFS_instance_iterator::visit_all_file_classes ( PFS_instance_visitor visitor)
static

◆ visit_all_file_instances()

void PFS_instance_iterator::visit_all_file_instances ( PFS_instance_visitor visitor)
static

◆ visit_all_mutex()

void PFS_instance_iterator::visit_all_mutex ( PFS_instance_visitor visitor)
static

◆ visit_all_mutex_classes()

void PFS_instance_iterator::visit_all_mutex_classes ( PFS_instance_visitor visitor)
static

◆ visit_all_mutex_instances()

void PFS_instance_iterator::visit_all_mutex_instances ( PFS_instance_visitor visitor)
static

◆ visit_all_rwlock()

void PFS_instance_iterator::visit_all_rwlock ( PFS_instance_visitor visitor)
static

◆ visit_all_rwlock_classes()

void PFS_instance_iterator::visit_all_rwlock_classes ( PFS_instance_visitor visitor)
static

◆ visit_all_rwlock_instances()

void PFS_instance_iterator::visit_all_rwlock_instances ( PFS_instance_visitor visitor)
static

◆ visit_all_tables()

void PFS_object_iterator::visit_all_tables ( PFS_object_visitor visitor)
static

Visit all tables and related handles.

◆ visit_cond()

void PFS_instance_wait_visitor::visit_cond ( PFS_cond )
virtual

Visit a cond instance.

Reimplemented from PFS_instance_visitor.

◆ visit_cond_class()

void PFS_instance_wait_visitor::visit_cond_class ( PFS_cond_class )
virtual

Visit a cond class.

Reimplemented from PFS_instance_visitor.

◆ visit_cond_instances()

void PFS_instance_iterator::visit_cond_instances ( PFS_cond_class klass,
PFS_instance_visitor visitor 
)
static

Visit a cond class and related instances.

Parameters
klassthe klass to visit.
visitorthe visitor to call

◆ visit_connection_slice() [1/2]

void PFS_connection_all_wait_visitor::visit_connection_slice ( PFS_connection_slice pfs)
private

◆ visit_connection_slice() [2/2]

void PFS_connection_all_statement_visitor::visit_connection_slice ( PFS_connection_slice pfs)
private

◆ visit_file() [1/2]

void PFS_instance_wait_visitor::visit_file ( PFS_file )
virtual

Visit a file instance.

Reimplemented from PFS_instance_visitor.

◆ visit_file() [2/2]

void PFS_instance_file_io_stat_visitor::visit_file ( PFS_file )
virtual

Visit a file instance.

Reimplemented from PFS_instance_visitor.

◆ visit_file_class() [1/2]

void PFS_instance_wait_visitor::visit_file_class ( PFS_file_class )
virtual

Visit a file class.

Reimplemented from PFS_instance_visitor.

◆ visit_file_class() [2/2]

void PFS_instance_file_io_stat_visitor::visit_file_class ( PFS_file_class )
virtual

Visit a file class.

Reimplemented from PFS_instance_visitor.

◆ visit_file_instances()

void PFS_instance_iterator::visit_file_instances ( PFS_file_class klass,
PFS_instance_visitor visitor 
)
static

Visit a file class and related instances.

Parameters
klassthe klass to visit.
visitorthe visitor to call

◆ visit_global() [1/14]

void PFS_connection_iterator::visit_global ( bool  with_hosts,
bool  with_users,
bool  with_accounts,
bool  with_threads,
bool  with_THDs,
PFS_connection_visitor visitor 
)
static

Visit all connections.

Connection iterator.

Parameters
with_hostswhen true, visit also all hosts.
with_userswhen true, visit also all users.
with_accountswhen true, visit also all user+host.
with_threadswhen true, visit also all threads.
with_THDswhen true, visit also all threads THD.
visitorthe visitor to call

◆ visit_global() [2/14]

void PFS_connection_wait_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [3/14]

void PFS_connection_all_wait_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [4/14]

void PFS_connection_stage_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [5/14]

void PFS_connection_statement_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [6/14]

void PFS_connection_all_statement_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [7/14]

void PFS_connection_transaction_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [8/14]

void PFS_connection_error_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [9/14]

void PFS_connection_stat_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [10/14]

void PFS_connection_memory_visitor::visit_global ( )
virtual

Visit all connections.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [11/14]

void PFS_connection_status_visitor::visit_global ( )
virtual

Aggregate from global status.

Reimplemented from PFS_connection_visitor.

◆ visit_global() [12/14]

void PFS_object_wait_visitor::visit_global ( )
virtual

Visit global data.

Reimplemented from PFS_object_visitor.

◆ visit_global() [13/14]

void PFS_table_io_wait_visitor::visit_global ( )
virtual

Visit global data.

Reimplemented from PFS_object_visitor.

◆ visit_global() [14/14]

void PFS_table_lock_wait_visitor::visit_global ( )
virtual

Visit global data.

Reimplemented from PFS_object_visitor.

◆ visit_host() [1/11]

void PFS_connection_iterator::visit_host ( PFS_host host,
bool  with_accounts,
bool  with_threads,
bool  with_THDs,
PFS_connection_visitor visitor 
)
static

Visit all connections of a host.

Parameters
hostthe host to visit.
with_accountswhen true, visit also all related user+host.
with_threadswhen true, visit also all related threads.
with_THDswhen true, visit also all related threads THD.
visitorthe visitor to call

◆ visit_host() [2/11]

void PFS_connection_wait_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [3/11]

void PFS_connection_all_wait_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [4/11]

void PFS_connection_stage_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [5/11]

void PFS_connection_statement_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [6/11]

void PFS_connection_all_statement_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [7/11]

void PFS_connection_transaction_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [8/11]

void PFS_connection_error_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [9/11]

void PFS_connection_stat_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [10/11]

void PFS_connection_memory_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_host() [11/11]

void PFS_connection_status_visitor::visit_host ( PFS_host )
virtual

Visit all connections of a host.

Reimplemented from PFS_connection_visitor.

◆ visit_instances()

void PFS_instance_iterator::visit_instances ( PFS_instr_class klass,
PFS_instance_visitor visitor,
PFS_thread thread,
bool  visit_class = true 
)
static

Visit an instrument class and related instances.

Generic instance iterator with PFS_thread as matching criteria.

Parameters
klassthe klass to visit.
visitorthe visitor to call
threadcomparison criteria
visit_classif true then visit the class

◆ visit_mutex()

void PFS_instance_wait_visitor::visit_mutex ( PFS_mutex )
virtual

Visit a mutex instance.

Reimplemented from PFS_instance_visitor.

◆ visit_mutex_class()

void PFS_instance_wait_visitor::visit_mutex_class ( PFS_mutex_class )
virtual

Visit a mutex class.

Reimplemented from PFS_instance_visitor.

◆ visit_mutex_instances()

void PFS_instance_iterator::visit_mutex_instances ( PFS_mutex_class klass,
PFS_instance_visitor visitor 
)
static

Visit a mutex class and related instances.

Instance iterator.

Parameters
klassthe klass to visit.
visitorthe visitor to call

◆ visit_rwlock()

void PFS_instance_wait_visitor::visit_rwlock ( PFS_rwlock )
virtual

Visit a rwlock instance.

Reimplemented from PFS_instance_visitor.

◆ visit_rwlock_class()

void PFS_instance_wait_visitor::visit_rwlock_class ( PFS_rwlock_class )
virtual

Visit a rwlock class.

Reimplemented from PFS_instance_visitor.

◆ visit_rwlock_instances()

void PFS_instance_iterator::visit_rwlock_instances ( PFS_rwlock_class klass,
PFS_instance_visitor visitor 
)
static

Visit a rwlock class and related instances.

Parameters
klassthe klass to visit.
visitorthe visitor to call

◆ visit_socket() [1/2]

void PFS_instance_wait_visitor::visit_socket ( PFS_socket )
virtual

Visit a socket instance.

Reimplemented from PFS_instance_visitor.

◆ visit_socket() [2/2]

void PFS_instance_socket_io_stat_visitor::visit_socket ( PFS_socket )
virtual

Visit a socket instance.

Reimplemented from PFS_instance_visitor.

◆ visit_socket_class() [1/2]

void PFS_instance_wait_visitor::visit_socket_class ( PFS_socket_class )
virtual

Visit a socket class.

Reimplemented from PFS_instance_visitor.

◆ visit_socket_class() [2/2]

void PFS_instance_socket_io_stat_visitor::visit_socket_class ( PFS_socket_class )
virtual

Visit a socket class.

Reimplemented from PFS_instance_visitor.

◆ visit_socket_instances() [1/2]

void PFS_instance_iterator::visit_socket_instances ( PFS_socket_class klass,
PFS_instance_visitor visitor 
)
static

Visit a socket class and related instances.

Socket instance iterator visiting a socket class and all instances.

Parameters
klassthe klass to visit.
visitorthe visitor to call

◆ visit_socket_instances() [2/2]

void PFS_instance_iterator::visit_socket_instances ( PFS_socket_class klass,
PFS_instance_visitor visitor,
PFS_thread thread,
bool  visit_class = true 
)
static

Visit a socket class and related instances.

Socket instance iterator visiting sockets owned by a PFS_thread.

Parameters
klassthe klass to visit.
visitorthe visitor to call
threadthe owning thread to match
visit_classif true then visit the socket class

◆ visit_table() [1/5]

void PFS_object_wait_visitor::visit_table ( PFS_table )
virtual

Visit a table.

Reimplemented from PFS_object_visitor.

◆ visit_table() [2/5]

void PFS_table_io_wait_visitor::visit_table ( PFS_table )
virtual

Visit a table.

Reimplemented from PFS_object_visitor.

◆ visit_table() [3/5]

void PFS_table_io_stat_visitor::visit_table ( PFS_table )
virtual

Visit a table.

Reimplemented from PFS_object_visitor.

◆ visit_table() [4/5]

void PFS_table_lock_wait_visitor::visit_table ( PFS_table )
virtual

Visit a table.

Reimplemented from PFS_object_visitor.

◆ visit_table() [5/5]

void PFS_table_lock_stat_visitor::visit_table ( PFS_table )
virtual

Visit a table.

Reimplemented from PFS_object_visitor.

◆ visit_table_index()

void PFS_index_io_stat_visitor::visit_table_index ( PFS_table ,
uint  index 
)
virtual

Visit a table index.

Reimplemented from PFS_object_visitor.

◆ visit_table_indexes()

void PFS_object_iterator::visit_table_indexes ( PFS_table_share share,
uint  index,
PFS_object_visitor visitor 
)
static

Visit a table index and related table handles indexes.

◆ visit_table_share() [1/5]

void PFS_object_wait_visitor::visit_table_share ( PFS_table_share )
virtual

Visit a table share.

Reimplemented from PFS_object_visitor.

◆ visit_table_share() [2/5]

void PFS_table_io_wait_visitor::visit_table_share ( PFS_table_share )
virtual

Visit a table share.

Reimplemented from PFS_object_visitor.

◆ visit_table_share() [3/5]

void PFS_table_io_stat_visitor::visit_table_share ( PFS_table_share )
virtual

Visit a table share.

Reimplemented from PFS_object_visitor.

◆ visit_table_share() [4/5]

void PFS_table_lock_wait_visitor::visit_table_share ( PFS_table_share )
virtual

Visit a table share.

Reimplemented from PFS_object_visitor.

◆ visit_table_share() [5/5]

void PFS_table_lock_stat_visitor::visit_table_share ( PFS_table_share )
virtual

Visit a table share.

Reimplemented from PFS_object_visitor.

◆ visit_table_share_index()

void PFS_index_io_stat_visitor::visit_table_share_index ( PFS_table_share ,
uint  index 
)
virtual

Visit a table share index.

Reimplemented from PFS_object_visitor.

◆ visit_tables()

void PFS_object_iterator::visit_tables ( PFS_table_share share,
PFS_object_visitor visitor 
)
static

Visit a table and related table handles.

◆ visit_THD() [1/2]

void PFS_connection_iterator::visit_THD ( THD thd,
PFS_connection_visitor visitor 
)
static

Visit THD.

Parameters
thdthe THD to visit.
visitorthe visitor to call.

◆ visit_THD() [2/2]

void PFS_connection_status_visitor::visit_THD ( THD )
virtual

Visit a THD associated with a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [1/10]

void PFS_connection_wait_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [2/10]

void PFS_connection_all_wait_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [3/10]

void PFS_connection_stage_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [4/10]

void PFS_connection_statement_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [5/10]

void PFS_connection_all_statement_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [6/10]

void PFS_connection_transaction_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [7/10]

void PFS_connection_error_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [8/10]

void PFS_connection_stat_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [9/10]

void PFS_connection_memory_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_thread() [10/10]

void PFS_connection_status_visitor::visit_thread ( PFS_thread )
virtual

Visit a thread.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [1/11]

void PFS_connection_iterator::visit_user ( PFS_user user,
bool  with_accounts,
bool  with_threads,
bool  with_THDs,
PFS_connection_visitor visitor 
)
static

Visit all connections of a user.

Parameters
userthe user to visit.
with_accountswhen true, visit also all related user+host.
with_threadswhen true, visit also all related threads.
with_THDswhen true, visit also all related threads THD.
visitorthe visitor to call

◆ visit_user() [2/11]

void PFS_connection_wait_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [3/11]

void PFS_connection_all_wait_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [4/11]

void PFS_connection_stage_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [5/11]

void PFS_connection_statement_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [6/11]

void PFS_connection_all_statement_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [7/11]

void PFS_connection_transaction_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [8/11]

void PFS_connection_error_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [9/11]

void PFS_connection_stat_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [10/11]

void PFS_connection_memory_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

◆ visit_user() [11/11]

void PFS_connection_status_visitor::visit_user ( PFS_user )
virtual

Visit all connections of a user.

Reimplemented from PFS_connection_visitor.

Variable Documentation

◆ account_hash [1/2]

LF_HASH account_hash

◆ account_hash [2/2]

LF_HASH account_hash

◆ account_hash_inited

bool account_hash_inited = false
static

◆ cond_class_allocated_count

std::atomic<uint32> cond_class_allocated_count {0}
static

◆ cond_class_array [1/2]

PFS_cond_class* cond_class_array = NULL

◆ cond_class_array [2/2]

PFS_cond_class* cond_class_array

◆ cond_class_dirty_count

std::atomic<uint32> cond_class_dirty_count {0}
static

◆ cond_class_lost [1/2]

ulong cond_class_lost = 0

Number of condition class lost.

See also
cond_class_array

◆ cond_class_lost [2/2]

ulong cond_class_lost

Number of condition class lost.

See also
cond_class_array

◆ cond_class_max [1/2]

ulong cond_class_max = 0

Size of the condition class array.

See also
cond_class_array

◆ cond_class_max [2/2]

ulong cond_class_max

Size of the condition class array.

See also
cond_class_array

◆ cond_class_start [1/2]

uint cond_class_start

◆ cond_class_start [2/2]

uint cond_class_start = 0

◆ error_class_max [1/2]

ulong error_class_max = 0

Number of error classes.

Although there is only one error class, this is kept for future use if there is more error classification required.

See also
global_error_class

◆ error_class_max [2/2]

ulong error_class_max

Number of error classes.

Although there is only one error class, this is kept for future use if there is more error classification required.

See also
global_error_class

◆ events_stages_history_per_thread [1/2]

ulong events_stages_history_per_thread = 0

Number of EVENTS_STAGES_HISTORY records per thread.

◆ events_stages_history_per_thread [2/2]

ulong events_stages_history_per_thread

Number of EVENTS_STAGES_HISTORY records per thread.

◆ events_statements_history_per_thread [1/2]

ulong events_statements_history_per_thread = 0

Number of EVENTS_STATEMENTS_HISTORY records per thread.

◆ events_statements_history_per_thread [2/2]

ulong events_statements_history_per_thread

Number of EVENTS_STATEMENTS_HISTORY records per thread.

◆ events_transactions_history_per_thread [1/2]

ulong events_transactions_history_per_thread = 0

Number of EVENTS_TRANSACTIONS_HISTORY records per thread.

◆ events_transactions_history_per_thread [2/2]

ulong events_transactions_history_per_thread

Number of EVENTS_TRANSACTIONS_HISTORY records per thread.

◆ events_waits_history_per_thread [1/2]

ulong events_waits_history_per_thread = 0

Number of EVENTS_WAITS_HISTORY records per thread.

◆ events_waits_history_per_thread [2/2]

ulong events_waits_history_per_thread

Number of EVENTS_WAITS_HISTORY records per thread.

◆ file_class_allocated_count

std::atomic<uint32> file_class_allocated_count {0}
static

◆ file_class_array [1/2]

PFS_file_class* file_class_array = NULL

◆ file_class_array [2/2]

PFS_file_class* file_class_array

◆ file_class_dirty_count

std::atomic<uint32> file_class_dirty_count {0}
static

◆ file_class_lost [1/2]

ulong file_class_lost = 0

Number of file class lost.

See also
file_class_array

◆ file_class_lost [2/2]

ulong file_class_lost

Number of file class lost.

See also
file_class_array

◆ file_class_max [1/2]

ulong file_class_max = 0

Size of the file class array.

See also
file_class_array

◆ file_class_max [2/2]

ulong file_class_max

Size of the file class array.

See also
file_class_array

◆ file_class_start [1/2]

uint file_class_start

◆ file_class_start [2/2]

uint file_class_start = 0

◆ file_handle_array [1/2]

PFS_file** file_handle_array = NULL

File instrumentation handle array.

See also
file_handle_max
file_handle_lost

◆ file_handle_array [2/2]

PFS_file** file_handle_array

File instrumentation handle array.

See also
file_handle_max
file_handle_lost

◆ file_handle_full

bool file_handle_full

True when file_handle_array is full.

◆ file_handle_lost [1/2]

ulong file_handle_lost = 0

Number of file handle lost.

See also
file_handle_array

◆ file_handle_lost [2/2]

ulong file_handle_lost

Number of file handle lost.

See also
file_handle_array

◆ file_handle_max [1/2]

long file_handle_max = 0

Size of the file handle array.

See also
file_handle_array. Signed value, for easier comparisons with a file descriptor number.

◆ file_handle_max [2/2]

long file_handle_max

Size of the file handle array.

See also
file_handle_array. Signed value, for easier comparisons with a file descriptor number.

◆ filename_hash [1/2]

LF_HASH filename_hash

Hash table for instrumented files.

◆ filename_hash [2/2]

LF_HASH filename_hash

Hash table for instrumented files.

◆ filename_hash_inited

bool filename_hash_inited = false
static

True if filename_hash is initialized.

◆ global_error_class [1/2]

PFS_ALIGNED PFS_error_class global_error_class

Instrument controlling all server errors.

◆ global_error_class [2/2]

PFS_error_class global_error_class

Instrument controlling all server errors.

◆ global_error_stat [1/2]

PFS_ALIGNED PFS_error_stat global_error_stat

Statistics for the error instrument.

◆ global_error_stat [2/2]

PFS_error_stat global_error_stat

Statistics for the error instrument.

◆ global_idle_class [1/2]

PFS_ALIGNED PFS_instr_class global_idle_class

Instrument controlling all idle waits.

◆ global_idle_class [2/2]

PFS_instr_class global_idle_class

Instrument controlling all idle waits.

◆ global_idle_stat [1/2]

PFS_ALIGNED PFS_single_stat global_idle_stat

Statistics for the IDLE instrument.

◆ global_idle_stat [2/2]

PFS_single_stat global_idle_stat

Statistics for the IDLE instrument.

◆ global_instr_class_memory_array [1/2]

std::atomic<PFS_memory_shared_stat *> global_instr_class_memory_array {nullptr}

◆ global_instr_class_memory_array [2/2]

std::atomic<PFS_memory_shared_stat *> global_instr_class_memory_array

◆ global_instr_class_stages_array [1/2]

PFS_stage_stat* global_instr_class_stages_array = NULL

◆ global_instr_class_stages_array [2/2]

PFS_stage_stat* global_instr_class_stages_array

◆ global_instr_class_statements_array [1/2]

PFS_statement_stat* global_instr_class_statements_array = NULL

◆ global_instr_class_statements_array [2/2]

PFS_statement_stat* global_instr_class_statements_array

◆ global_metadata_class [1/2]

PFS_ALIGNED PFS_instr_class global_metadata_class

Instrument controlling all metadata locks.

◆ global_metadata_class [2/2]

PFS_instr_class global_metadata_class

Instrument controlling all metadata locks.

◆ global_metadata_stat [1/2]

PFS_ALIGNED PFS_single_stat global_metadata_stat

Statistics for the METADATA instrument.

◆ global_metadata_stat [2/2]

PFS_single_stat global_metadata_stat

Statistics for the METADATA instrument.

◆ global_statements_histogram [1/2]

PFS_histogram global_statements_histogram

◆ global_statements_histogram [2/2]

PFS_histogram global_statements_histogram

◆ global_table_io_class [1/2]

PFS_ALIGNED PFS_instr_class global_table_io_class

Instrument controlling all table I/O.

This instrument is used with table SETUP_OBJECTS.

◆ global_table_io_class [2/2]

PFS_instr_class global_table_io_class

Instrument controlling all table I/O.

This instrument is used with table SETUP_OBJECTS.

◆ global_table_io_stat [1/2]

PFS_ALIGNED PFS_table_io_stat global_table_io_stat

Statistics for dropped table I/O.

◆ global_table_io_stat [2/2]

PFS_table_io_stat global_table_io_stat

Statistics for dropped table I/O.

◆ global_table_lock_class [1/2]

PFS_ALIGNED PFS_instr_class global_table_lock_class

Instrument controlling all table lock.

This instrument is used with table SETUP_OBJECTS.

◆ global_table_lock_class [2/2]

PFS_instr_class global_table_lock_class

Instrument controlling all table lock.

This instrument is used with table SETUP_OBJECTS.

◆ global_table_lock_stat [1/2]

PFS_ALIGNED PFS_table_lock_stat global_table_lock_stat

Statistics for dropped table lock.

◆ global_table_lock_stat [2/2]

PFS_table_lock_stat global_table_lock_stat

Statistics for dropped table lock.

◆ global_transaction_class [1/2]

PFS_ALIGNED PFS_transaction_class global_transaction_class

◆ global_transaction_class [2/2]

PFS_transaction_class global_transaction_class

◆ global_transaction_stat [1/2]

PFS_ALIGNED PFS_transaction_stat global_transaction_stat

Statistics for the transaction instrument.

◆ global_transaction_stat [2/2]

PFS_transaction_stat global_transaction_stat

Statistics for the transaction instrument.

◆ host_hash [1/2]

LF_HASH host_hash

◆ host_hash [2/2]

LF_HASH host_hash

◆ host_hash_inited

bool host_hash_inited = false
static

◆ locker_lost [1/2]

ulong locker_lost = 0

Number of locker lost.

See also
LOCKER_STACK_SIZE.

◆ locker_lost [2/2]

ulong locker_lost

Number of locker lost.

See also
LOCKER_STACK_SIZE.

◆ memory_class_allocated_count

std::atomic<uint32> memory_class_allocated_count {0}
static

◆ memory_class_array

std::atomic<PFS_memory_class *> memory_class_array {nullptr}
static

◆ memory_class_dirty_count

std::atomic<uint32> memory_class_dirty_count {0}
static

◆ memory_class_lost [1/2]

ulong memory_class_lost = 0

Number of memory class lost.

See also
memory_class_array

◆ memory_class_lost [2/2]

ulong memory_class_lost

Number of memory class lost.

See also
memory_class_array

◆ memory_class_max [1/2]

ulong memory_class_max = 0

Size of the memory class array.

See also
memory_class_array

◆ memory_class_max [2/2]

ulong memory_class_max

Size of the memory class array.

See also
memory_class_array

◆ mutex_class_allocated_count

std::atomic<uint32> mutex_class_allocated_count {0}
static

◆ mutex_class_array [1/2]

PFS_mutex_class* mutex_class_array = NULL

◆ mutex_class_array [2/2]

PFS_mutex_class* mutex_class_array

◆ mutex_class_dirty_count

std::atomic<uint32> mutex_class_dirty_count {0}
static

Current number of elements in mutex_class_array.

This global variable is written to during:

  • the performance schema initialization
  • a plugin initialization

◆ mutex_class_lost [1/2]

ulong mutex_class_lost = 0

Number of mutex class lost.

See also
mutex_class_array

◆ mutex_class_lost [2/2]

ulong mutex_class_lost

Number of mutex class lost.

See also
mutex_class_array

◆ mutex_class_max [1/2]

ulong mutex_class_max = 0

Size of the mutex class array.

See also
mutex_class_array

◆ mutex_class_max [2/2]

ulong mutex_class_max

Size of the mutex class array.

See also
mutex_class_array

◆ mutex_class_start [1/2]

uint mutex_class_start

◆ mutex_class_start [2/2]

uint mutex_class_start = 0

◆ pfs_enabled [1/2]

bool pfs_enabled = true

Global performance schema flag.

Indicate if the performance schema is enabled. This flag is set at startup, and never changes.

◆ pfs_enabled [2/2]

bool pfs_enabled

Global performance schema flag.

Indicate if the performance schema is enabled. This flag is set at startup, and never changes.

◆ pfs_instr_config_array [1/2]

Pfs_instr_config_array* pfs_instr_config_array = NULL

PFS_INSTRUMENT option settings array.

◆ pfs_instr_config_array [2/2]

Pfs_instr_config_array* pfs_instr_config_array

PFS_INSTRUMENT option settings array.

◆ pfs_max_digest_length [1/2]

size_t pfs_max_digest_length = 0

Max size of the digests token array.

◆ pfs_max_digest_length [2/2]

size_t pfs_max_digest_length

Max size of the digests token array.

◆ pfs_max_sqltext [1/2]

size_t pfs_max_sqltext = 0

Max size of SQL TEXT.

◆ pfs_max_sqltext [2/2]

size_t pfs_max_sqltext

Max size of SQL TEXT.

◆ pfs_unload_plugin_ref_count

std::atomic<uint32> pfs_unload_plugin_ref_count

Global ref count for plugin and component events.

◆ rwlock_class_allocated_count

std::atomic<uint32> rwlock_class_allocated_count {0}
static

◆ rwlock_class_array [1/2]

PFS_rwlock_class* rwlock_class_array = NULL

◆ rwlock_class_array [2/2]

PFS_rwlock_class* rwlock_class_array

◆ rwlock_class_dirty_count

std::atomic<uint32> rwlock_class_dirty_count {0}
static

◆ rwlock_class_lost [1/2]

ulong rwlock_class_lost = 0

Number of rwlock class lost.

See also
rwlock_class_array

◆ rwlock_class_lost [2/2]

ulong rwlock_class_lost

Number of rwlock class lost.

See also
rwlock_class_array

◆ rwlock_class_max [1/2]

ulong rwlock_class_max = 0

Size of the rwlock class array.

See also
rwlock_class_array

◆ rwlock_class_max [2/2]

ulong rwlock_class_max

Size of the rwlock class array.

See also
rwlock_class_array

◆ rwlock_class_start [1/2]

uint rwlock_class_start

◆ rwlock_class_start [2/2]

uint rwlock_class_start = 0

◆ session_connect_attrs_longest_seen [1/2]

ulong session_connect_attrs_longest_seen = 0

Longest connection attributes string seen so far, pre-truncation.

◆ session_connect_attrs_longest_seen [2/2]

ulong session_connect_attrs_longest_seen

Longest connection attributes string seen so far, pre-truncation.

◆ session_connect_attrs_lost [1/2]

ulong session_connect_attrs_lost = 0

Number of connection attributes lost.

◆ session_connect_attrs_lost [2/2]

ulong session_connect_attrs_lost

Number of connection attributes lost.

◆ session_connect_attrs_size_per_thread [1/2]

ulong session_connect_attrs_size_per_thread

Size of connection attribute storage per thread.

◆ session_connect_attrs_size_per_thread [2/2]

ulong session_connect_attrs_size_per_thread

Size of connection attribute storage per thread.

◆ setup_actor_hash [1/2]

LF_HASH setup_actor_hash

Hash table for setup_actor records.

◆ setup_actor_hash [2/2]

LF_HASH setup_actor_hash

Hash table for setup_actor records.

◆ setup_actor_hash_inited

bool setup_actor_hash_inited = false
static

True if setup_actor_hash is initialized.

◆ setup_object_hash [1/2]

LF_HASH setup_object_hash

◆ setup_object_hash [2/2]

LF_HASH setup_object_hash

◆ setup_object_hash_inited

bool setup_object_hash_inited = false
static

◆ setup_objects_version

uint setup_objects_version = 0

◆ socket_class_allocated_count

std::atomic<uint32> socket_class_allocated_count {0}
static

◆ socket_class_array

PFS_socket_class* socket_class_array = NULL
static

◆ socket_class_dirty_count

std::atomic<uint32> socket_class_dirty_count {0}
static

◆ socket_class_lost [1/2]

ulong socket_class_lost = 0

Number of socket class lost.

See also
socket_class_array

◆ socket_class_lost [2/2]

ulong socket_class_lost

Number of socket class lost.

See also
socket_class_array

◆ socket_class_max [1/2]

ulong socket_class_max = 0

Size of the socket class array.

See also
socket_class_array

◆ socket_class_max [2/2]

ulong socket_class_max

Size of the socket class array.

See also
socket_class_array

◆ socket_class_start [1/2]

uint socket_class_start

◆ socket_class_start [2/2]

uint socket_class_start = 0

◆ stage_class_allocated_count

std::atomic<uint32> stage_class_allocated_count {0}
static

◆ stage_class_array

PFS_stage_class* stage_class_array = NULL
static

◆ stage_class_dirty_count

std::atomic<uint32> stage_class_dirty_count {0}
static

◆ stage_class_lost [1/2]

ulong stage_class_lost = 0

Number of stage class lost.

See also
stage_class_array

◆ stage_class_lost [2/2]

ulong stage_class_lost

Number of stage class lost.

See also
stage_class_array

◆ stage_class_max [1/2]

ulong stage_class_max = 0

Size of the stage class array.

See also
stage_class_array

◆ stage_class_max [2/2]

ulong stage_class_max

Size of the stage class array.

See also
stage_class_array

◆ statement_class_allocated_count

std::atomic<uint32> statement_class_allocated_count {0}
static

◆ statement_class_array