MySQL 8.4.3
Source Code Documentation
|
The performance schema implementation of all instruments. More...
#include "storage/perfschema/pfs.h"
#include "my_config.h"
#include <assert.h>
#include <errno.h>
#include <fcntl.h>
#include <mysql/components/component_implementation.h>
#include <mysql/components/service.h>
#include <mysql/components/service_implementation.h>
#include <mysql/components/services/mysql_server_telemetry_metrics_service.h>
#include <mysql/components/services/mysql_server_telemetry_traces_service.h>
#include <mysql/components/services/pfs_notification.h>
#include <mysql/components/services/psi_cond_service.h>
#include <mysql/components/services/psi_error_service.h>
#include <mysql/components/services/psi_file_service.h>
#include <mysql/components/services/psi_idle_service.h>
#include <mysql/components/services/psi_mdl_service.h>
#include <mysql/components/services/psi_memory_service.h>
#include <mysql/components/services/psi_metric_service.h>
#include <mysql/components/services/psi_mutex_service.h>
#include <mysql/components/services/psi_rwlock_service.h>
#include <mysql/components/services/psi_socket_service.h>
#include <mysql/components/services/psi_stage_service.h>
#include <mysql/components/services/psi_statement_service.h>
#include <mysql/components/services/psi_system_service.h>
#include <mysql/components/services/psi_table_service.h>
#include <mysql/components/services/psi_thread_service.h>
#include <mysql/components/services/psi_tls_channel_service.h>
#include <mysql/components/services/psi_transaction_service.h>
#include <sys/types.h>
#include <time.h>
#include "lex_string.h"
#include "my_compiler.h"
#include "my_inttypes.h"
#include "my_io.h"
#include "my_macros.h"
#include "my_thread.h"
#include "mysql/psi/mysql_memory.h"
#include "mysql/psi/mysql_thread.h"
#include "mysql/psi/psi_metric.h"
#include "mysql/strings/m_ctype.h"
#include "pfs_error_provider.h"
#include "pfs_file_provider.h"
#include "pfs_idle_provider.h"
#include "pfs_memory_provider.h"
#include "pfs_metadata_provider.h"
#include "pfs_metric_provider.h"
#include "pfs_socket_provider.h"
#include "pfs_stage_provider.h"
#include "pfs_statement_provider.h"
#include "pfs_system_provider.h"
#include "pfs_table_provider.h"
#include "pfs_thread_provider.h"
#include "pfs_transaction_provider.h"
#include "sql/mdl.h"
#include "sql/sp_head.h"
#include "sql/sql_const.h"
#include "sql/sql_digest.h"
#include "sql/sql_error.h"
#include "storage/perfschema/mysql_server_telemetry_traces_service_imp.h"
#include "storage/perfschema/pfs_account.h"
#include "storage/perfschema/pfs_column_values.h"
#include "storage/perfschema/pfs_data_lock.h"
#include "storage/perfschema/pfs_digest.h"
#include "storage/perfschema/pfs_error.h"
#include "storage/perfschema/pfs_events_stages.h"
#include "storage/perfschema/pfs_events_statements.h"
#include "storage/perfschema/pfs_events_transactions.h"
#include "storage/perfschema/pfs_events_waits.h"
#include "storage/perfschema/pfs_global.h"
#include "storage/perfschema/pfs_host.h"
#include "storage/perfschema/pfs_instr.h"
#include "storage/perfschema/pfs_instr_class.h"
#include "storage/perfschema/pfs_metrics_service_imp.h"
#include "storage/perfschema/pfs_plugin_table.h"
#include "storage/perfschema/pfs_prepared_stmt.h"
#include "storage/perfschema/pfs_program.h"
#include "storage/perfschema/pfs_services.h"
#include "storage/perfschema/pfs_setup_actor.h"
#include "storage/perfschema/pfs_setup_object.h"
#include "storage/perfschema/pfs_timer.h"
#include "storage/perfschema/pfs_tls_channel.h"
#include "storage/perfschema/pfs_user.h"
#include "storage/perfschema/service_pfs_notification.h"
#include "thr_lock.h"
Classes | |
struct | PFS_spawn_thread_arg |
Arguments given from a parent to a child thread, packaged in one structure. More... | |
Macros | |
#define | HAVE_PSI_COND_INTERFACE |
#define | HAVE_PSI_DATA_LOCK_INTERFACE |
#define | HAVE_PSI_ERROR_INTERFACE |
#define | HAVE_PSI_FILE_INTERFACE |
#define | HAVE_PSI_IDLE_INTERFACE |
#define | HAVE_PSI_MEMORY_INTERFACE |
#define | HAVE_PSI_METADATA_INTERFACE |
#define | HAVE_PSI_MUTEX_INTERFACE |
#define | HAVE_PSI_PS_INTERFACE |
#define | HAVE_PSI_RWLOCK_INTERFACE |
#define | HAVE_PSI_SOCKET_INTERFACE |
#define | HAVE_PSI_SP_INTERFACE |
#define | HAVE_PSI_STAGE_INTERFACE |
#define | HAVE_PSI_STATEMENT_DIGEST_INTERFACE |
#define | HAVE_PSI_STATEMENT_INTERFACE |
#define | HAVE_PSI_SYSTEM_INTERFACE |
#define | HAVE_PSI_TABLE_INTERFACE |
#define | HAVE_PSI_THREAD_INTERFACE |
#define | HAVE_PSI_TRANSACTION_INTERFACE |
#define | HAVE_PSI_TLS_CHANNEL_INTERFACE |
#define | HAVE_PSI_2 |
#define | DISABLE_PSI_COND |
Compiling option to disable the cond instrumentation. More... | |
#define | DISABLE_PSI_DATA_LOCK |
Compiling option to disable the data lock instrumentation. More... | |
#define | DISABLE_PSI_ERROR |
Compiling option to disable the error instrumentation. More... | |
#define | DISABLE_PSI_FILE |
Compiling option to disable the file instrumentation. More... | |
#define | DISABLE_PSI_IDLE |
Compiling option to disable the idle instrumentation. More... | |
#define | DISABLE_PSI_MEMORY |
Compiling option to disable the memory instrumentation. More... | |
#define | DISABLE_PSI_METADATA |
Compiling option to disable the metadata instrumentation. More... | |
#define | DISABLE_PSI_METRICS |
Compiling option to disable MySQL Server Telemetry metrics instrumentation. More... | |
#define | DISABLE_PSI_MUTEX |
Compiling option to disable the mutex instrumentation. More... | |
#define | DISABLE_PSI_PS |
Compiling option to disable the prepared statement instrumentation. More... | |
#define | DISABLE_PSI_RWLOCK |
Compiling option to disable the rwlock instrumentation. More... | |
#define | DISABLE_PSI_SOCKET |
Compiling option to disable the statement instrumentation. More... | |
#define | DISABLE_PSI_SP |
Compiling option to disable the stored program instrumentation. More... | |
#define | DISABLE_PSI_STAGE |
Compiling option to disable the stage instrumentation. More... | |
#define | DISABLE_PSI_STATEMENT |
Compiling option to disable the statement instrumentation. More... | |
#define | DISABLE_PSI_STATEMENT_DIGEST |
Compiling option to disable the statement digest instrumentation. More... | |
#define | DISABLE_PSI_SYSTEM |
Compiling option to disable the system instrumentation. More... | |
#define | DISABLE_PSI_TABLE |
Compiling option to disable the table instrumentation. More... | |
#define | DISABLE_PSI_THREAD |
Compiling option to disable the thread instrumentation. More... | |
#define | DISABLE_PSI_TRANSACTION |
Compiling option to disable the transaction instrumentation. More... | |
#define | DISABLE_PSI_TLS_CHANNEL |
Compiling option to disable TLS Channel instrumentation. More... | |
#define | DISABLE_PSI_SERVER_TELEMETRY_TRACES |
Compiling option to disable MySQL Server Telemetry traces instrumentation. More... | |
#define | DEBUG_TRACE_MEMORY(P1, P2, P3, P4) |
#define | REGISTER_BODY_V1(KEY_T, PREFIX, REGISTER_FUNC) |
#define | SET_STATEMENT_ATTR_BODY(LOCKER, ATTR, VALUE) |
#define | INC_STATEMENT_ATTR_BODY(LOCKER, ATTR, VALUE) |
#define | INC_TRANSACTION_ATTR_BODY(LOCKER, ATTR, VALUE) |
#define | REFERENCES_SERVICE(component, service) const_cast<void *>((const void *)&SERVICE_IMPLEMENTATION(component, service)) |
Functions | |
static void | adjust_collect_flags (PSI_statement_locker_state *state) |
Recompute collection flags. More... | |
static PFS_thread * | my_thread_get_THR_PFS () |
void | record_main_thread_id () |
static void | pfs_thread_setname (PFS_thread *pfs) |
static void | my_thread_set_THR_PFS (PFS_thread *pfs) |
static int | build_prefix (const LEX_CSTRING *prefix, const char *category, char *output, size_t *output_length) |
Build the prefix name of a class of instruments in a category. More... | |
void | pfs_register_mutex_v1 (const char *category, PSI_mutex_info_v1 *info, int count) |
Implementation of the mutex instrumentation interface. More... | |
void | pfs_register_rwlock_v2 (const char *category, PSI_rwlock_info_v1 *info, int count) |
Implementation of the rwlock instrumentation interface. More... | |
void | pfs_register_cond_v1 (const char *category, PSI_cond_info_v1 *info, int count) |
Implementation of the cond instrumentation interface. More... | |
void | pfs_register_thread_vc (const char *category, PSI_thread_info *info, int count) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_register_thread_v1 (const char *category, PSI_thread_info_v1 *info, int count) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_register_file_vc (const char *category, PSI_file_info_v1 *info, int count) |
Implementation of the file instrumentation interface. More... | |
void | pfs_register_stage_v1 (const char *category, PSI_stage_info_v1 **info_array, int count) |
void | pfs_register_statement_vc (const char *category, PSI_statement_info *info, int count) |
void | pfs_register_socket_v1 (const char *category, PSI_socket_info_v1 *info, int count) |
PSI_mutex * | pfs_init_mutex_v1 (PSI_mutex_key key, const void *identity) |
Implementation of the mutex instrumentation interface. More... | |
void | pfs_destroy_mutex_v1 (PSI_mutex *mutex) |
Implementation of the mutex instrumentation interface. More... | |
PSI_rwlock * | pfs_init_rwlock_v2 (PSI_rwlock_key key, const void *identity) |
Implementation of the rwlock instrumentation interface. More... | |
void | pfs_destroy_rwlock_v2 (PSI_rwlock *rwlock) |
Implementation of the rwlock instrumentation interface. More... | |
PSI_cond * | pfs_init_cond_v1 (PSI_cond_key key, const void *identity) |
Implementation of the cond instrumentation interface. More... | |
void | pfs_destroy_cond_v1 (PSI_cond *cond) |
Implementation of the cond instrumentation interface. More... | |
PSI_table_share * | pfs_get_table_share_v1 (bool temporary, TABLE_SHARE *share) |
Implementation of the table instrumentation interface. More... | |
void | pfs_release_table_share_v1 (PSI_table_share *share) |
Implementation of the table instrumentation interface. More... | |
void | pfs_drop_table_share_v1 (bool temporary, const char *schema_name, int schema_name_length, const char *table_name, int table_name_length) |
Implementation of the table instrumentation interface. More... | |
PSI_table * | pfs_open_table_v1 (PSI_table_share *share, const void *identity) |
Implementation of the table instrumentation interface. More... | |
void | pfs_unbind_table_v1 (PSI_table *table) |
Implementation of the table instrumentation interface. More... | |
PSI_table * | pfs_rebind_table_v1 (PSI_table_share *share, const void *identity, PSI_table *table) |
Implementation of the table instrumentation interface. More... | |
void | pfs_close_table_v1 (TABLE_SHARE *server_share, PSI_table *table) |
Implementation of the table instrumentation interface. More... | |
PSI_socket * | pfs_init_socket_v1 (PSI_socket_key key, const my_socket *fd, const struct sockaddr *addr, socklen_t addr_len) |
void | pfs_destroy_socket_v1 (PSI_socket *socket) |
void | pfs_create_file_vc (PSI_file_key key, const char *name, File file) |
Implementation of the file instrumentation interface. More... | |
static void * | pfs_spawn_thread (void *arg) |
int | pfs_spawn_thread_vc (PSI_thread_key key, PSI_thread_seqnum seqnum, my_thread_handle *thread, const my_thread_attr_t *attr, void *(*start_routine)(void *), void *arg) |
Implementation of the thread instrumentation interface. More... | |
int | pfs_spawn_thread_v4 (PSI_thread_key key, my_thread_handle *thread, const my_thread_attr_t *attr, void *(*start_routine)(void *), void *arg) |
PSI_thread * | pfs_new_thread_vc (PSI_thread_key key, PSI_thread_seqnum seqnum, const void *identity, ulonglong processlist_id) |
Implementation of the thread instrumentation interface. More... | |
PSI_thread * | pfs_new_thread_v4 (PSI_thread_key key, const void *identity, ulonglong processlist_id) |
void | pfs_set_thread_id_vc (PSI_thread *thread, ulonglong processlist_id) |
Implementation of the thread instrumentation interface. More... | |
ulonglong | pfs_get_current_thread_internal_id_vc () |
Implementation of the thread instrumentation interface. More... | |
ulonglong | pfs_get_thread_internal_id_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
PSI_thread * | pfs_get_thread_by_id_vc (ulonglong processlist_id) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_THD_vc (PSI_thread *thread, THD *thd) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_mem_cnt_THD_vc (THD *thd, THD **backup_thd) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_os_id_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
PSI_thread * | pfs_get_thread_vc () |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_user_vc (const char *user, int user_len) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_account_vc (const char *user, int user_len, const char *host, int host_len) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_db_vc (const char *db, int db_len) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_command_vc (int command) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_connection_type_vc (opaque_vio_type conn_type) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_start_time_vc (time_t start_time) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_state_v1 (const char *) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_info_vc (const char *info, uint info_len) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_secondary_engine_vc (bool secondary) |
Implementation of the thread instrumentation interface. More... | |
int | set_thread_resource_group (PFS_thread *pfs, const char *group_name, int group_name_len, void *user_data) |
Set the resource group name for a given thread. More... | |
int | pfs_set_thread_resource_group_vc (const char *group_name, int group_name_len, void *user_data) |
Implementation of the thread instrumentation interface. More... | |
int | pfs_set_thread_resource_group_by_id_vc (PSI_thread *thread, ulonglong thread_id, const char *group_name, int group_name_len, void *user_data) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_get_thread_system_attrs (PFS_thread *pfs, PSI_thread_attrs *thread_attrs) |
int | get_thread_attributes (PFS_thread *pfs, bool current_thread, PSI_thread_attrs *thread_attrs) |
Get the system and session attributes for a given PFS_thread. More... | |
int | pfs_get_thread_system_attrs_vc (PSI_thread_attrs *thread_attrs) |
Implementation of the thread instrumentation interface. More... | |
int | pfs_get_thread_system_attrs_by_id_vc (PSI_thread *thread, ulonglong thread_id, PSI_thread_attrs *thread_attrs) |
Implementation of the thread instrumentation interface. More... | |
int | pfs_register_notification_vc (const PSI_notification *callbacks, bool with_ref_count) |
Implementation of the thread instrumentation interface. More... | |
int | pfs_unregister_notification_vc (int handle) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_notify_session_connect_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_notify_session_disconnect_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_notify_session_change_user_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_set_thread_peer_port_vc (PSI_thread *thread, uint port) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_aggregate_thread_status_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_delete_current_thread_vc () |
Implementation of the thread instrumentation interface. More... | |
void | pfs_delete_thread_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_detect_telemetry_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
void | pfs_abort_telemetry_vc (PSI_thread *thread) |
Implementation of the thread instrumentation interface. More... | |
PSI_mutex_locker * | pfs_start_mutex_wait_v1 (PSI_mutex_locker_state *state, PSI_mutex *mutex, PSI_mutex_operation op, const char *src_file, uint src_line) |
Implementation of the mutex instrumentation interface. More... | |
static PSI_rwlock_locker * | pfs_start_rwlock_wait_v2 (PSI_rwlock_locker_state *state, PSI_rwlock *rwlock, PSI_rwlock_operation op, const char *src_file, uint src_line) |
Implementation of the rwlock instrumentation interface. More... | |
PSI_rwlock_locker * | pfs_start_rwlock_rdwait_v2 (PSI_rwlock_locker_state *state, PSI_rwlock *rwlock, PSI_rwlock_operation op, const char *src_file, uint src_line) |
PSI_rwlock_locker * | pfs_start_rwlock_wrwait_v2 (PSI_rwlock_locker_state *state, PSI_rwlock *rwlock, PSI_rwlock_operation op, const char *src_file, uint src_line) |
PSI_cond_locker * | pfs_start_cond_wait_v1 (PSI_cond_locker_state *state, PSI_cond *cond, PSI_mutex *mutex, PSI_cond_operation op, const char *src_file, uint src_line) |
Implementation of the cond instrumentation interface. More... | |
static PFS_TL_LOCK_TYPE | lock_flags_to_lock_type (uint flags) |
static PFS_TL_LOCK_TYPE | external_lock_flags_to_lock_type (uint flags) |
PSI_table_locker * | pfs_start_table_io_wait_v1 (PSI_table_locker_state *state, PSI_table *table, PSI_table_io_operation op, uint index, const char *src_file, uint src_line) |
Implementation of the table instrumentation interface. More... | |
PSI_table_locker * | pfs_start_table_lock_wait_v1 (PSI_table_locker_state *state, PSI_table *table, PSI_table_lock_operation op, ulong op_flags, const char *src_file, uint src_line) |
Implementation of the table instrumentation interface. More... | |
PSI_file_locker * | pfs_get_thread_file_name_locker_vc (PSI_file_locker_state *state, PSI_file_key key, PSI_file_operation op, const char *name, const void *) |
Implementation of the file instrumentation interface. More... | |
PSI_file_locker * | pfs_get_thread_file_stream_locker_vc (PSI_file_locker_state *state, PSI_file *file, PSI_file_operation op) |
Implementation of the file instrumentation interface. More... | |
PSI_file_locker * | pfs_get_thread_file_descriptor_locker_vc (PSI_file_locker_state *state, File file, PSI_file_operation op) |
Implementation of the file instrumentation interface. More... | |
PSI_socket_locker * | pfs_start_socket_wait_v1 (PSI_socket_locker_state *state, PSI_socket *socket, PSI_socket_operation op, size_t count, const char *src_file, uint src_line) |
Socket locker. More... | |
void | pfs_unlock_mutex_v1 (PSI_mutex *mutex) |
Implementation of the mutex instrumentation interface. More... | |
void | pfs_unlock_rwlock_v2 (PSI_rwlock *rwlock, PSI_rwlock_operation op) |
Implementation of the rwlock instrumentation interface. More... | |
void | pfs_signal_cond_v1 (PSI_cond *cond) |
Implementation of the cond instrumentation interface. More... | |
void | pfs_broadcast_cond_v1 (PSI_cond *cond) |
Implementation of the cond instrumentation interface. More... | |
PSI_idle_locker * | pfs_start_idle_wait_v1 (PSI_idle_locker_state *state, const char *src_file, uint src_line) |
Implementation of the idle instrumentation interface. More... | |
void | pfs_end_idle_wait_v1 (PSI_idle_locker *locker) |
Implementation of the mutex instrumentation interface. More... | |
void | pfs_end_mutex_wait_v1 (PSI_mutex_locker *locker, int rc) |
Implementation of the mutex instrumentation interface. More... | |
void | pfs_end_rwlock_rdwait_v2 (PSI_rwlock_locker *locker, int rc) |
Implementation of the rwlock instrumentation interface. More... | |
void | pfs_end_rwlock_wrwait_v2 (PSI_rwlock_locker *locker, int rc) |
Implementation of the rwlock instrumentation interface. More... | |
void | pfs_end_cond_wait_v1 (PSI_cond_locker *locker, int) |
Implementation of the cond instrumentation interface. More... | |
void | pfs_end_table_io_wait_v1 (PSI_table_locker *locker, ulonglong numrows) |
Implementation of the table instrumentation interface. More... | |
void | pfs_end_table_lock_wait_v1 (PSI_table_locker *locker) |
Implementation of the table instrumentation interface. More... | |
void | pfs_start_file_wait_vc (PSI_file_locker *locker, size_t count, const char *src_file, uint src_line) |
Implementation of the file instrumentation interface. More... | |
void | pfs_end_file_wait_vc (PSI_file_locker *locker, size_t byte_count) |
Implementation of the file instrumentation interface. More... | |
void | pfs_start_file_open_wait_vc (PSI_file_locker *locker, const char *src_file, uint src_line) |
Implementation of the file instrumentation interface. More... | |
PSI_file * | pfs_end_file_open_wait_vc (PSI_file_locker *locker, void *result) |
Implementation of the file instrumentation interface. More... | |
void | pfs_end_file_open_wait_and_bind_to_descriptor_vc (PSI_file_locker *locker, File file) |
Implementation of the file instrumentation interface. More... | |
void | pfs_end_temp_file_open_wait_and_bind_to_descriptor_vc (PSI_file_locker *locker, File file, const char *filename) |
Implementation of the file instrumentation interface. More... | |
void | pfs_start_file_close_wait_vc (PSI_file_locker *locker, const char *src_file, uint src_line) |
Implementation of the file instrumentation interface. More... | |
void | pfs_end_file_close_wait_vc (PSI_file_locker *locker, int rc) |
Implementation of the file instrumentation interface. More... | |
void | pfs_start_file_rename_wait_vc (PSI_file_locker *locker, size_t count, const char *old_name, const char *new_name, const char *src_file, uint src_line) |
Implementation of the file instrumentation interface. More... | |
void | pfs_end_file_rename_wait_vc (PSI_file_locker *locker, const char *old_name, const char *new_name, int rc) |
Implementation of the file instrumentation interface. More... | |
PSI_stage_progress * | pfs_start_stage_v1 (PSI_stage_key key, const char *src_file, int src_line) |
PSI_stage_progress * | pfs_get_current_stage_progress_v1 () |
void | pfs_end_stage_v1 () |
PSI_statement_locker * | pfs_get_thread_statement_locker_vc (PSI_statement_locker_state *state, PSI_statement_key key, const void *charset, PSI_sp_share *sp_share) |
This is the entry point to the performance schema statement instrumentation. More... | |
PSI_statement_locker * | pfs_refine_statement_vc (PSI_statement_locker *locker, PSI_statement_key key) |
void | pfs_start_statement_vc (PSI_statement_locker *locker, const char *db, uint db_len, const char *src_file, uint src_line) |
void | pfs_set_statement_text_vc (PSI_statement_locker *locker, const char *text, uint text_len) |
void | pfs_set_statement_query_id_vc (PSI_statement_locker *locker, ulonglong query_id) |
void | pfs_set_statement_lock_time_vc (PSI_statement_locker *locker, ulonglong count) |
void | pfs_set_statement_rows_sent_vc (PSI_statement_locker *locker, ulonglong count) |
void | pfs_set_statement_rows_examined_vc (PSI_statement_locker *locker, ulonglong count) |
void | pfs_inc_statement_created_tmp_disk_tables_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_created_tmp_tables_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_select_full_join_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_select_full_range_join_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_select_range_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_select_range_check_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_select_scan_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_sort_merge_passes_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_sort_range_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_sort_rows_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_inc_statement_sort_scan_vc (PSI_statement_locker *locker, ulong count) |
void | pfs_set_statement_no_index_used_vc (PSI_statement_locker *locker) |
void | pfs_set_statement_no_good_index_used_vc (PSI_statement_locker *locker) |
void | pfs_set_statement_secondary_engine_vc (PSI_statement_locker *locker, bool secondary) |
void | pfs_end_statement_vc (PSI_statement_locker *locker, void *stmt_da) |
static enum_object_type | sp_type_to_object_type (uint sp_type) |
static PSI_sp_share * | pfs_get_sp_share_vc (uint sp_type, const char *schema_name, uint schema_name_length, const char *object_name, uint object_name_length) |
Implementation of the stored program instrumentation interface. More... | |
static void | pfs_release_sp_share_vc (PSI_sp_share *) |
static PSI_sp_locker * | pfs_start_sp_vc (PSI_sp_locker_state *state, PSI_sp_share *sp_share) |
static void | pfs_end_sp_vc (PSI_sp_locker *locker) |
static void | pfs_drop_sp_vc (uint sp_type, const char *schema_name, uint schema_name_length, const char *object_name, uint object_name_length) |
void | pfs_notify_statement_query_attributes_vc (PSI_statement_locker *locker, bool with_query_attributes) |
void | pfs_statement_abort_telemetry_vc (PSI_statement_locker *locker) |
PSI_transaction_locker * | pfs_get_thread_transaction_locker_v1 (PSI_transaction_locker_state *state, const void *xid, const ulonglong *trxid, int isolation_level, bool read_only, bool autocommit) |
void | pfs_start_transaction_v1 (PSI_transaction_locker *locker, const char *src_file, uint src_line) |
void | pfs_set_transaction_gtid_v1 (PSI_transaction_locker *locker, const void *sid, const void *gtid_spec) |
void | pfs_set_transaction_xid_v1 (PSI_transaction_locker *locker, const void *xid, int xa_state) |
void | pfs_set_transaction_xa_state_v1 (PSI_transaction_locker *locker, int xa_state) |
void | pfs_set_transaction_trxid_v1 (PSI_transaction_locker *locker, const ulonglong *trxid) |
void | pfs_inc_transaction_savepoints_v1 (PSI_transaction_locker *locker, ulong count) |
void | pfs_inc_transaction_rollback_to_savepoint_v1 (PSI_transaction_locker *locker, ulong count) |
void | pfs_inc_transaction_release_savepoint_v1 (PSI_transaction_locker *locker, ulong count) |
void | pfs_end_transaction_v1 (PSI_transaction_locker *locker, bool commit) |
void | pfs_end_socket_wait_v1 (PSI_socket_locker *locker, size_t byte_count) |
Implementation of the socket instrumentation interface. More... | |
void | pfs_set_socket_state_v1 (PSI_socket *socket, PSI_socket_state state) |
void | pfs_set_socket_info_v1 (PSI_socket *socket, const my_socket *fd, const struct sockaddr *addr, socklen_t addr_len) |
Set socket descriptor and address info. More... | |
void | pfs_set_socket_thread_owner_v1 (PSI_socket *socket) |
Implementation of the socket instrumentation interface. More... | |
struct PSI_digest_locker * | pfs_digest_start_vc (PSI_statement_locker *locker) |
void | pfs_digest_end_vc (PSI_digest_locker *locker, const sql_digest_storage *digest) |
PSI_prepared_stmt * | pfs_create_prepared_stmt_vc (void *identity, uint stmt_id, PSI_statement_locker *locker, const char *stmt_name, size_t stmt_name_length, const char *sql_text, size_t sql_text_length) |
void | pfs_execute_prepared_stmt_vc (PSI_statement_locker *locker, PSI_prepared_stmt *ps) |
void | pfs_destroy_prepared_stmt_vc (PSI_prepared_stmt *prepared_stmt) |
void | pfs_reprepare_prepared_stmt_vc (PSI_prepared_stmt *prepared_stmt) |
void | pfs_set_prepared_stmt_text_vc (PSI_prepared_stmt *prepared_stmt, const char *text, uint text_len) |
void | pfs_set_prepared_stmt_secondary_engine_vc (PSI_prepared_stmt *prepared_stmt, bool secondary) |
int | pfs_set_thread_connect_attrs_vc (const char *buffer, uint length, const void *from_cs) |
Implementation of the thread attribute connection interface. More... | |
void | pfs_get_current_thread_event_id_vc (ulonglong *internal_thread_id, ulonglong *event_id) |
Implementation of the get event id interface. More... | |
void | pfs_get_thread_event_id_v1 (ulonglong *internal_thread_id, ulonglong *event_id) |
Implementation of the get event id interface. More... | |
void | pfs_get_thread_event_id_vc (PSI_thread *psi, ulonglong *internal_thread_id, ulonglong *event_id) |
Implementation of the get event id interface. More... | |
void | pfs_register_memory_vc (const char *category, PSI_memory_info_v1 *info, int count) |
PSI_memory_key | pfs_memory_alloc_vc (PSI_memory_key key, size_t size, PSI_thread **owner) |
PSI_memory_key | pfs_memory_realloc_vc (PSI_memory_key key, size_t old_size, size_t new_size, PSI_thread **owner) |
PSI_memory_key | pfs_memory_claim_vc (PSI_memory_key key, size_t size, PSI_thread **owner, bool claim) |
void | pfs_memory_free_vc (PSI_memory_key key, size_t size, PSI_thread *owner) |
void | pfs_unlock_table_v1 (PSI_table *table) |
PSI_metadata_lock * | pfs_create_metadata_lock_vc (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 | pfs_set_metadata_lock_status_vc (PSI_metadata_lock *lock, opaque_mdl_status mdl_status) |
void | pfs_set_metadata_lock_duration_vc (PSI_metadata_lock *lock, opaque_mdl_duration mdl_duration) |
void | pfs_destroy_metadata_lock_vc (PSI_metadata_lock *lock) |
PSI_metadata_locker * | pfs_start_metadata_wait_vc (PSI_metadata_locker_state *state, PSI_metadata_lock *lock, const char *src_file, uint src_line) |
void | pfs_end_metadata_wait_vc (PSI_metadata_locker *locker, int) |
void | pfs_log_error_v1 (uint error_num, PSI_error_operation error_operation) |
void | pfs_register_data_lock_v1 (PSI_engine_data_lock_inspector *inspector) |
void | pfs_unregister_data_lock_v1 (PSI_engine_data_lock_inspector *) |
void | pfs_unload_plugin_v1 (const char *plugin_name) |
Implementation of the thread instrumentation interface. More... | |
const mysql_service_psi_thread_v4_t | SERVICE_IMPLEMENTATION (performance_schema, psi_thread_v4) |
const mysql_service_psi_thread_v5_t | SERVICE_IMPLEMENTATION (performance_schema, psi_thread_v5) |
const mysql_service_psi_thread_v6_t | SERVICE_IMPLEMENTATION (performance_schema, psi_thread_v6) |
const mysql_service_psi_thread_v7_t | SERVICE_IMPLEMENTATION (performance_schema, psi_thread_v7) |
const mysql_service_psi_mutex_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_mutex_v1) |
const mysql_service_psi_rwlock_v2_t | SERVICE_IMPLEMENTATION (performance_schema, psi_rwlock_v2) |
const mysql_service_psi_cond_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_cond_v1) |
const mysql_service_psi_file_v2_t | SERVICE_IMPLEMENTATION (performance_schema, psi_file_v2) |
const mysql_service_psi_socket_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_socket_v1) |
const mysql_service_psi_table_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_table_v1) |
const mysql_service_psi_mdl_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_mdl_v1) |
const mysql_service_psi_mdl_v2_t | SERVICE_IMPLEMENTATION (performance_schema, psi_mdl_v2) |
const mysql_service_psi_idle_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_idle_v1) |
const mysql_service_psi_stage_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_stage_v1) |
const mysql_service_psi_statement_v5_t | SERVICE_IMPLEMENTATION (performance_schema, psi_statement_v5) |
const mysql_service_psi_transaction_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_transaction_v1) |
const mysql_service_psi_memory_v2_t | SERVICE_IMPLEMENTATION (performance_schema, psi_memory_v2) |
const mysql_service_psi_error_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_error_v1) |
const mysql_service_psi_tls_channel_v1_t | SERVICE_IMPLEMENTATION (performance_schema, psi_tls_channel_v1) |
static void * | get_system_interface (int version) |
static void * | get_thread_interface (int version) |
static void * | get_mutex_interface (int version) |
static void * | get_rwlock_interface (int version) |
static void * | get_cond_interface (int version) |
static void * | get_file_interface (int version) |
static void * | get_socket_interface (int version) |
static void * | get_table_interface (int version) |
static void * | get_mdl_interface (int version) |
static void * | get_idle_interface (int version) |
static void * | get_stage_interface (int version) |
static void * | get_statement_interface (int version) |
static void * | get_transaction_interface (int version) |
static void * | get_memory_interface (int version) |
static void * | get_error_interface (int version) |
static void * | get_data_lock_interface (int version) |
static void * | get_tls_channel_interface (int version) |
void * | get_services () |
The performance schema implementation of all instruments.
#define DEBUG_TRACE_MEMORY | ( | P1, | |
P2, | |||
P3, | |||
P4 | |||
) |
#define DISABLE_PSI_COND |
Compiling option to disable the cond instrumentation.
#define DISABLE_PSI_DATA_LOCK |
Compiling option to disable the data lock instrumentation.
#define DISABLE_PSI_ERROR |
Compiling option to disable the error instrumentation.
#define DISABLE_PSI_FILE |
Compiling option to disable the file instrumentation.
#define DISABLE_PSI_IDLE |
Compiling option to disable the idle instrumentation.
#define DISABLE_PSI_MEMORY |
Compiling option to disable the memory instrumentation.
#define DISABLE_PSI_METADATA |
Compiling option to disable the metadata instrumentation.
#define DISABLE_PSI_METRICS |
Compiling option to disable MySQL Server Telemetry metrics instrumentation.
#define DISABLE_PSI_MUTEX |
Compiling option to disable the mutex instrumentation.
This option is mostly intended to be used during development, when doing special builds with only a subset of the performance schema instrumentation, for code analysis / profiling / performance tuning of a specific instrumentation alone.
#define DISABLE_PSI_PS |
Compiling option to disable the prepared statement instrumentation.
#define DISABLE_PSI_RWLOCK |
Compiling option to disable the rwlock instrumentation.
#define DISABLE_PSI_SERVER_TELEMETRY_TRACES |
Compiling option to disable MySQL Server Telemetry traces instrumentation.
#define DISABLE_PSI_SOCKET |
Compiling option to disable the statement instrumentation.
#define DISABLE_PSI_SP |
Compiling option to disable the stored program instrumentation.
#define DISABLE_PSI_STAGE |
Compiling option to disable the stage instrumentation.
#define DISABLE_PSI_STATEMENT |
Compiling option to disable the statement instrumentation.
#define DISABLE_PSI_STATEMENT_DIGEST |
Compiling option to disable the statement digest instrumentation.
#define DISABLE_PSI_SYSTEM |
Compiling option to disable the system instrumentation.
#define DISABLE_PSI_TABLE |
Compiling option to disable the table instrumentation.
#define DISABLE_PSI_THREAD |
Compiling option to disable the thread instrumentation.
#define DISABLE_PSI_TLS_CHANNEL |
Compiling option to disable TLS Channel instrumentation.
#define DISABLE_PSI_TRANSACTION |
Compiling option to disable the transaction instrumentation.
#define HAVE_PSI_2 |
#define HAVE_PSI_COND_INTERFACE |
#define HAVE_PSI_DATA_LOCK_INTERFACE |
#define HAVE_PSI_ERROR_INTERFACE |
#define HAVE_PSI_FILE_INTERFACE |
#define HAVE_PSI_IDLE_INTERFACE |
#define HAVE_PSI_MEMORY_INTERFACE |
#define HAVE_PSI_METADATA_INTERFACE |
#define HAVE_PSI_MUTEX_INTERFACE |
#define HAVE_PSI_PS_INTERFACE |
#define HAVE_PSI_RWLOCK_INTERFACE |
#define HAVE_PSI_SOCKET_INTERFACE |
#define HAVE_PSI_SP_INTERFACE |
#define HAVE_PSI_STAGE_INTERFACE |
#define HAVE_PSI_STATEMENT_DIGEST_INTERFACE |
#define HAVE_PSI_STATEMENT_INTERFACE |
#define HAVE_PSI_SYSTEM_INTERFACE |
#define HAVE_PSI_TABLE_INTERFACE |
#define HAVE_PSI_THREAD_INTERFACE |
#define HAVE_PSI_TLS_CHANNEL_INTERFACE |
#define HAVE_PSI_TRANSACTION_INTERFACE |
#define INC_STATEMENT_ATTR_BODY | ( | LOCKER, | |
ATTR, | |||
VALUE | |||
) |
#define INC_TRANSACTION_ATTR_BODY | ( | LOCKER, | |
ATTR, | |||
VALUE | |||
) |
#define REFERENCES_SERVICE | ( | component, | |
service | |||
) | const_cast<void *>((const void *)&SERVICE_IMPLEMENTATION(component, service)) |
#define REGISTER_BODY_V1 | ( | KEY_T, | |
PREFIX, | |||
REGISTER_FUNC | |||
) |
#define SET_STATEMENT_ATTR_BODY | ( | LOCKER, | |
ATTR, | |||
VALUE | |||
) |
|
static |
Recompute collection flags.
This helper adjusts the internal collection flags, based on the current telemetry requests.
[in,out] | state | Statement instrumentation internal state |
Input: PSI_statement_locker_state::pfs_flags
PSI_statement_locker_state::m_telemetry_scope
Output: PSI_statement_locker_state::m_collect_flags
PSI_statement_locker_state::m_tel_flags
|
static |
Build the prefix name of a class of instruments in a category.
For example, this function builds the string 'wait/sync/mutex/sql/' from a prefix 'wait/sync/mutex' and a category 'sql'. This prefix is used later to build each instrument name, such as 'wait/sync/mutex/sql/LOCK_open'.
prefix | Prefix for this class of instruments | |
category | Category name | |
[out] | output | Buffer of length PFS_MAX_INFO_NAME_LENGTH. |
[out] | output_length | Length of the resulting output string. |
|
inlinestatic |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
void * get_services | ( | ) |
|
static |
|
static |
|
static |
|
static |
|
static |
int get_thread_attributes | ( | PFS_thread * | pfs, |
bool | current_thread, | ||
PSI_thread_attrs * | thread_attrs | ||
) |
Get the system and session attributes for a given PFS_thread.
pfs | thread instrumentation |
current_thread | true if pfs refers to the current thread |
thread_attrs | thread attribute structure |
|
static |
|
static |
|
static |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
void pfs_abort_telemetry_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_aggregate_thread_status_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_broadcast_cond_v1 | ( | PSI_cond * | cond | ) |
Implementation of the cond instrumentation interface.
void pfs_close_table_v1 | ( | TABLE_SHARE * | server_share, |
PSI_table * | table | ||
) |
Implementation of the table instrumentation interface.
void pfs_create_file_vc | ( | PSI_file_key | key, |
const char * | name, | ||
File | file | ||
) |
Implementation of the file instrumentation interface.
PSI_metadata_lock * pfs_create_metadata_lock_vc | ( | 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 | ||
) |
PSI_prepared_stmt * pfs_create_prepared_stmt_vc | ( | void * | identity, |
uint | stmt_id, | ||
PSI_statement_locker * | locker, | ||
const char * | stmt_name, | ||
size_t | stmt_name_length, | ||
const char * | sql_text, | ||
size_t | sql_text_length | ||
) |
void pfs_delete_current_thread_vc | ( | void | ) |
Implementation of the thread instrumentation interface.
void pfs_delete_thread_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_destroy_cond_v1 | ( | PSI_cond * | cond | ) |
Implementation of the cond instrumentation interface.
void pfs_destroy_metadata_lock_vc | ( | PSI_metadata_lock * | lock | ) |
void pfs_destroy_mutex_v1 | ( | PSI_mutex * | mutex | ) |
Implementation of the mutex instrumentation interface.
void pfs_destroy_prepared_stmt_vc | ( | PSI_prepared_stmt * | prepared_stmt | ) |
void pfs_destroy_rwlock_v2 | ( | PSI_rwlock * | rwlock | ) |
Implementation of the rwlock instrumentation interface.
void pfs_destroy_socket_v1 | ( | PSI_socket * | socket | ) |
void pfs_detect_telemetry_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_digest_end_vc | ( | PSI_digest_locker * | locker, |
const sql_digest_storage * | digest | ||
) |
struct PSI_digest_locker * pfs_digest_start_vc | ( | PSI_statement_locker * | locker | ) |
|
static |
void pfs_drop_table_share_v1 | ( | bool | temporary, |
const char * | schema_name, | ||
int | schema_name_length, | ||
const char * | table_name, | ||
int | table_name_length | ||
) |
Implementation of the table instrumentation interface.
void pfs_end_cond_wait_v1 | ( | PSI_cond_locker * | locker, |
int | rc | ||
) |
Implementation of the cond instrumentation interface.
void pfs_end_file_close_wait_vc | ( | PSI_file_locker * | locker, |
int | rc | ||
) |
Implementation of the file instrumentation interface.
void pfs_end_file_open_wait_and_bind_to_descriptor_vc | ( | PSI_file_locker * | locker, |
File | file | ||
) |
Implementation of the file instrumentation interface.
PSI_file * pfs_end_file_open_wait_vc | ( | PSI_file_locker * | locker, |
void * | result | ||
) |
Implementation of the file instrumentation interface.
void pfs_end_file_rename_wait_vc | ( | PSI_file_locker * | locker, |
const char * | old_name, | ||
const char * | new_name, | ||
int | rc | ||
) |
Implementation of the file instrumentation interface.
void pfs_end_file_wait_vc | ( | PSI_file_locker * | locker, |
size_t | byte_count | ||
) |
Implementation of the file instrumentation interface.
void pfs_end_idle_wait_v1 | ( | PSI_idle_locker * | locker | ) |
Implementation of the mutex instrumentation interface.
void pfs_end_metadata_wait_vc | ( | PSI_metadata_locker * | locker, |
int | rc | ||
) |
void pfs_end_mutex_wait_v1 | ( | PSI_mutex_locker * | locker, |
int | rc | ||
) |
Implementation of the mutex instrumentation interface.
void pfs_end_rwlock_rdwait_v2 | ( | PSI_rwlock_locker * | locker, |
int | rc | ||
) |
Implementation of the rwlock instrumentation interface.
void pfs_end_rwlock_wrwait_v2 | ( | PSI_rwlock_locker * | locker, |
int | rc | ||
) |
Implementation of the rwlock instrumentation interface.
void pfs_end_socket_wait_v1 | ( | PSI_socket_locker * | locker, |
size_t | byte_count | ||
) |
Implementation of the socket instrumentation interface.
|
static |
void pfs_end_stage_v1 | ( | ) |
void pfs_end_statement_vc | ( | PSI_statement_locker * | locker, |
void * | stmt_da | ||
) |
void pfs_end_table_io_wait_v1 | ( | PSI_table_locker * | locker, |
ulonglong | numrows | ||
) |
Implementation of the table instrumentation interface.
void pfs_end_table_lock_wait_v1 | ( | PSI_table_locker * | locker | ) |
Implementation of the table instrumentation interface.
void pfs_end_temp_file_open_wait_and_bind_to_descriptor_vc | ( | PSI_file_locker * | locker, |
File | file, | ||
const char * | filename | ||
) |
Implementation of the file instrumentation interface.
void pfs_end_transaction_v1 | ( | PSI_transaction_locker * | locker, |
bool | commit | ||
) |
void pfs_execute_prepared_stmt_vc | ( | PSI_statement_locker * | locker, |
PSI_prepared_stmt * | ps | ||
) |
PSI_stage_progress * pfs_get_current_stage_progress_v1 | ( | ) |
Implementation of the get event id interface.
ulonglong pfs_get_current_thread_internal_id_vc | ( | ) |
Implementation of the thread instrumentation interface.
|
static |
Implementation of the stored program instrumentation interface.
PSI_table_share * pfs_get_table_share_v1 | ( | bool | temporary, |
TABLE_SHARE * | share | ||
) |
Implementation of the table instrumentation interface.
PSI_thread * pfs_get_thread_by_id_vc | ( | ulonglong | processlist_id | ) |
Implementation of the thread instrumentation interface.
Implementation of the get event id interface.
void pfs_get_thread_event_id_vc | ( | PSI_thread * | psi, |
ulonglong * | internal_thread_id, | ||
ulonglong * | event_id | ||
) |
Implementation of the get event id interface.
PSI_file_locker * pfs_get_thread_file_descriptor_locker_vc | ( | PSI_file_locker_state * | state, |
File | file, | ||
PSI_file_operation | op | ||
) |
Implementation of the file instrumentation interface.
PSI_file_locker * pfs_get_thread_file_name_locker_vc | ( | PSI_file_locker_state * | state, |
PSI_file_key | key, | ||
PSI_file_operation | op, | ||
const char * | name, | ||
const void * | identity | ||
) |
Implementation of the file instrumentation interface.
PSI_file_locker * pfs_get_thread_file_stream_locker_vc | ( | PSI_file_locker_state * | state, |
PSI_file * | file, | ||
PSI_file_operation | op | ||
) |
Implementation of the file instrumentation interface.
ulonglong pfs_get_thread_internal_id_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
PSI_statement_locker * pfs_get_thread_statement_locker_vc | ( | PSI_statement_locker_state * | state, |
PSI_statement_key | key, | ||
const void * | charset, | ||
PSI_sp_share * | sp_share | ||
) |
This is the entry point to the performance schema statement instrumentation.
This instrumentation is used to:
These two data paths are executed in parallel, based on data collected once, and possibly used twice for different purposes.
is used to collect data.
How each field in PSI_statement_locker_state is used is described here, not in PSI_statement_locker_state, because usage is specific to the implementation.
Other instrumentations of the PSI interface, (namely, LOCK_ORDER), may choose to use fields differently, or not at all.
Fields in PSI_statement_locker_state are used as follows.
PSI_statement_locker_state::m_class
Statement instrument class. Always populated. Not null.
PSI_statement_locker_state::m_cs_number
Always populated. Character set number, for query text.
PSI_statement_locker_state::m_thread
Thread instrumentation. Always populated. May be null.
PSI_statement_locker_state::m_parent_sp_share
Parent stored program instrumentation. Always populated. May be null.
PSI_statement_locker_state::m_pfs_flags
Flags controlling how collected data is used to feed performance schema tables. Always populated.
Bits have the following semantic:
In addition, the following filters are implemented:
PSI_statement_locker_state::m_telemetry_scope
These flags are set by the telemetry traces component, to indicate if/how to collect data for telemetry. Never populated, when not compiling with telemetry. Always populated, when compiling with telemetry.
Possible values are:
0
, to indicate statement traces are not collected.TRACE_STATEMENTS
, to indicate statement traces are required.These values are exposed in the mysql_server_telemetry_traces_v1 service, and part of the public mysql_server_telemetry_traces interface.
Subsequent calls to telemetry trace apis can narrow down flags, but can never add more flags.
PSI_statement_locker_state::m_tel_flags
These flags are a translation, in performance schema implementation terms, of interface PSI_statement_locker_state::m_telemetry_scope. Never populated, when not compiling with telemetry traces. Always populated, when compiling with telemetry traces.
Bits have the following semantic:
In practice, these flags are not set individually. See STATE_FLAG_STATEMENT_TELEMETRY.
PSI_statement_locker_state::m_collect_flags
Flags controlling data collection. These flags are the union of m_pfs_flags
and m_telemetry_scope
Always populated.
A value 0 indicates nothing is collected.
PSI_statement_locker_state::m_telemetry_locker
Opaque pointer to a telemetry span inside the telemetry component. Never populated, when not compiling with telemetry. Always populated, when compiling with telemetry. May be NULL.
PSI_statement_locker_state::m_telemetry
Pointer to the telemetry traces component code.
Typed as a void* pointer in public headers, to avoid exposing implementation details. The effective type is guaranteed to be
which is the component entry point loaded by INSTALL COMPONENT <telemetry.so>
Never populated, when not compiling with telemetry traces. Conditionally populated, when compiling with telemetry traces. Not NULL if populated.
This member is initialized only when m_telemetry_locker != nullptr. It points to the telemetry traces component that created the m_telemetry_locker.
When m_telemetry_locker == nullptr, this member is not set.
PSI_statement_locker_state::m_telemetry_session
Pointer to a telemetry session, inside the telemetry component.
Never populated, when not compiling with telemetry traces. Conditionally populated, when compiling with telemetry traces. Not NULL if populated.
This member is initialized only when m_telemetry_locker != nullptr. It points to the telemetry session associated with the m_telemetry_locker.
When m_telemetry_locker == nullptr, this member is not set.
PSI_statement_locker_state::m_controlled_local_size_start
PSI_statement_locker_state::m_controlled_stmt_size_start
PSI_statement_locker_state::m_total_local_size_start
PSI_statement_locker_state::m_total_stmt_size_start
Temporary storage used by the instrumentation to compute the amount of memory used by a sub statement.
Conditionally populated, several conditions apply:
Used to compute MAX_CONTROLLED_MEMORY and MAX_TOTAL_MEMORY.
PSI_statement_locker_state::m_timer_start
Statement timing information. Conditionally populated, if m_collect_flags != 0. May be 0.
Value set only when bit STATE_FLAG_TIMED is set in m_collect_flags.
Note that m_collect_flags & STATE_FLAG_TIMED can be true, while m_pfs_flags & STATE_FLAG_TIMED can be false, so check the proper flag before using this field.
PSI_statement_locker_state::m_cpu_time_start
CPU timing information. Conditionally populated, if m_collect_flags != 0. May be 0.
Value set only when bit STATE_FLAG_CPU is set in m_collect_flags.
Note that m_collect_flags & STATE_FLAG_CPU can be true, while m_pfs_flags & STATE_FLAG_CPU can be false, so check the proper flag before using this field.
PSI_statement_locker_state::m_no_index_used
PSI_statement_locker_state::m_no_good_index_used
PSI_statement_locker_state::m_lock_time
PSI_statement_locker_state::m_rows_sent
PSI_statement_locker_state::m_rows_examined
PSI_statement_locker_state::m_created_tmp_disk_tables
PSI_statement_locker_state::m_created_tmp_tables
PSI_statement_locker_state::m_select_full_join
PSI_statement_locker_state::m_select_full_range_join
PSI_statement_locker_state::m_select_range
PSI_statement_locker_state::m_select_range_check
PSI_statement_locker_state::m_select_scan
PSI_statement_locker_state::m_sort_merge_passes
PSI_statement_locker_state::m_sort_range
PSI_statement_locker_state::m_sort_rows
PSI_statement_locker_state::m_sort_scan
Optimizer metrics associated with a statement. Conditionally populated, if m_collect_flags & STATE_FLAG_BASE.
PSI_statement_locker_state::m_digest
Query digest. Conditionally populated, if m_collect_flags != 0. May be NULL.
Value set only when bit STATE_FLAG_DIGEST is set in m_collect_flags.
PSI_statement_locker_state::m_schema_name
PSI_statement_locker_state::m_schema_name_length
Current schema. Conditionally populated, if m_collect_flags != 0. May be empty.
PSI_statement_locker_state::m_query_sample
PSI_statement_locker_state::m_query_sample_length
PSI_statement_locker_state::m_query_sample_truncated
Query sample. Conditionally populated, if m_collect_flags != 0. May be empty.
PSI_statement_locker_state::m_secondary
Secondary engine. Conditionally populated, if m_collect_flags != 0.
PSI_statement_locker_state::m_parent_prepared_stmt
Parent prepare statement. Conditionally populated, if m_collect_flags != 0. May be NULL.
PSI_statement_locker_state::m_in_prepare
Prepare or Execute the parent prepared statement. Conditionally populated:
If a parent prepared statement exists, indicate if the code prepares (true) or executes (false) the parent statement.
PSI_statement_locker_state::m_statement
Performance schema STATEMENT_CURRENT record. Conditionally populated, if m_collect_flags != 0. May be NULL.
Value set only if pfs_flags & STATE_FLAG_EVENT
void pfs_get_thread_system_attrs | ( | PFS_thread * | pfs, |
PSI_thread_attrs * | thread_attrs | ||
) |
int pfs_get_thread_system_attrs_by_id_vc | ( | PSI_thread * | thread, |
ulonglong | thread_id, | ||
PSI_thread_attrs * | thread_attrs | ||
) |
Implementation of the thread instrumentation interface.
int pfs_get_thread_system_attrs_vc | ( | PSI_thread_attrs * | thread_attrs | ) |
Implementation of the thread instrumentation interface.
PSI_transaction_locker * pfs_get_thread_transaction_locker_v1 | ( | PSI_transaction_locker_state * | state, |
const void * | xid, | ||
const ulonglong * | trxid, | ||
int | isolation_level, | ||
bool | read_only, | ||
bool | autocommit | ||
) |
PSI_thread * pfs_get_thread_vc | ( | void | ) |
Implementation of the thread instrumentation interface.
void pfs_inc_statement_created_tmp_disk_tables_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_created_tmp_tables_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_select_full_join_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_select_full_range_join_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_select_range_check_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_select_range_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_select_scan_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_sort_merge_passes_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_sort_range_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_sort_rows_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_statement_sort_scan_vc | ( | PSI_statement_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_transaction_release_savepoint_v1 | ( | PSI_transaction_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_transaction_rollback_to_savepoint_v1 | ( | PSI_transaction_locker * | locker, |
ulong | count | ||
) |
void pfs_inc_transaction_savepoints_v1 | ( | PSI_transaction_locker * | locker, |
ulong | count | ||
) |
PSI_cond * pfs_init_cond_v1 | ( | PSI_cond_key | key, |
const void * | identity | ||
) |
Implementation of the cond instrumentation interface.
PSI_mutex * pfs_init_mutex_v1 | ( | PSI_mutex_key | key, |
const void * | identity | ||
) |
Implementation of the mutex instrumentation interface.
PSI_rwlock * pfs_init_rwlock_v2 | ( | PSI_rwlock_key | key, |
const void * | identity | ||
) |
Implementation of the rwlock instrumentation interface.
PSI_socket * pfs_init_socket_v1 | ( | PSI_socket_key | key, |
const my_socket * | fd, | ||
const struct sockaddr * | addr, | ||
socklen_t | addr_len | ||
) |
void pfs_log_error_v1 | ( | uint | error_num, |
PSI_error_operation | error_operation | ||
) |
PSI_memory_key pfs_memory_alloc_vc | ( | PSI_memory_key | key, |
size_t | size, | ||
PSI_thread ** | owner | ||
) |
PSI_memory_key pfs_memory_claim_vc | ( | PSI_memory_key | key, |
size_t | size, | ||
PSI_thread ** | owner, | ||
bool | claim | ||
) |
void pfs_memory_free_vc | ( | PSI_memory_key | key, |
size_t | size, | ||
PSI_thread * | owner | ||
) |
PSI_memory_key pfs_memory_realloc_vc | ( | PSI_memory_key | key, |
size_t | old_size, | ||
size_t | new_size, | ||
PSI_thread ** | owner | ||
) |
PSI_thread * pfs_new_thread_v4 | ( | PSI_thread_key | key, |
const void * | identity, | ||
ulonglong | processlist_id | ||
) |
PSI_thread * pfs_new_thread_vc | ( | PSI_thread_key | key, |
PSI_thread_seqnum | seqnum, | ||
const void * | identity, | ||
ulonglong | processlist_id | ||
) |
Implementation of the thread instrumentation interface.
void pfs_notify_session_change_user_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_notify_session_connect_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_notify_session_disconnect_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_notify_statement_query_attributes_vc | ( | PSI_statement_locker * | locker, |
bool | with_query_attributes | ||
) |
PSI_table * pfs_open_table_v1 | ( | PSI_table_share * | share, |
const void * | identity | ||
) |
Implementation of the table instrumentation interface.
PSI_table * pfs_rebind_table_v1 | ( | PSI_table_share * | share, |
const void * | identity, | ||
PSI_table * | table | ||
) |
Implementation of the table instrumentation interface.
PSI_statement_locker * pfs_refine_statement_vc | ( | PSI_statement_locker * | locker, |
PSI_statement_key | key | ||
) |
void pfs_register_cond_v1 | ( | const char * | category, |
PSI_cond_info_v1 * | info, | ||
int | count | ||
) |
Implementation of the cond instrumentation interface.
void pfs_register_data_lock_v1 | ( | PSI_engine_data_lock_inspector * | inspector | ) |
void pfs_register_file_vc | ( | const char * | category, |
PSI_file_info_v1 * | info, | ||
int | count | ||
) |
Implementation of the file instrumentation interface.
void pfs_register_memory_vc | ( | const char * | category, |
PSI_memory_info_v1 * | info, | ||
int | count | ||
) |
void pfs_register_mutex_v1 | ( | const char * | category, |
PSI_mutex_info_v1 * | info, | ||
int | count | ||
) |
Implementation of the mutex instrumentation interface.
int pfs_register_notification_vc | ( | const PSI_notification * | callbacks, |
bool | with_ref_count | ||
) |
Implementation of the thread instrumentation interface.
void pfs_register_rwlock_v2 | ( | const char * | category, |
PSI_rwlock_info_v1 * | info, | ||
int | count | ||
) |
Implementation of the rwlock instrumentation interface.
void pfs_register_socket_v1 | ( | const char * | category, |
PSI_socket_info_v1 * | info, | ||
int | count | ||
) |
void pfs_register_stage_v1 | ( | const char * | category, |
PSI_stage_info_v1 ** | info_array, | ||
int | count | ||
) |
void pfs_register_statement_vc | ( | const char * | category, |
PSI_statement_info * | info, | ||
int | count | ||
) |
void pfs_register_thread_v1 | ( | const char * | category, |
PSI_thread_info_v1 * | info, | ||
int | count | ||
) |
Implementation of the thread instrumentation interface.
void pfs_register_thread_vc | ( | const char * | category, |
PSI_thread_info * | info, | ||
int | count | ||
) |
Implementation of the thread instrumentation interface.
|
static |
void pfs_release_table_share_v1 | ( | PSI_table_share * | share | ) |
Implementation of the table instrumentation interface.
void pfs_reprepare_prepared_stmt_vc | ( | PSI_prepared_stmt * | prepared_stmt | ) |
void pfs_set_connection_type_vc | ( | opaque_vio_type | conn_type | ) |
Implementation of the thread instrumentation interface.
Implementation of the thread instrumentation interface.
void pfs_set_metadata_lock_duration_vc | ( | PSI_metadata_lock * | lock, |
opaque_mdl_duration | mdl_duration | ||
) |
void pfs_set_metadata_lock_status_vc | ( | PSI_metadata_lock * | lock, |
opaque_mdl_status | mdl_status | ||
) |
void pfs_set_prepared_stmt_secondary_engine_vc | ( | PSI_prepared_stmt * | prepared_stmt, |
bool | secondary | ||
) |
void pfs_set_prepared_stmt_text_vc | ( | PSI_prepared_stmt * | prepared_stmt, |
const char * | text, | ||
uint | text_len | ||
) |
void pfs_set_socket_info_v1 | ( | PSI_socket * | socket, |
const my_socket * | fd, | ||
const struct sockaddr * | addr, | ||
socklen_t | addr_len | ||
) |
Set socket descriptor and address info.
void pfs_set_socket_state_v1 | ( | PSI_socket * | socket, |
PSI_socket_state | state | ||
) |
void pfs_set_socket_thread_owner_v1 | ( | PSI_socket * | socket | ) |
Implementation of the socket instrumentation interface.
void pfs_set_statement_lock_time_vc | ( | PSI_statement_locker * | locker, |
ulonglong | count | ||
) |
void pfs_set_statement_no_good_index_used_vc | ( | PSI_statement_locker * | locker | ) |
void pfs_set_statement_no_index_used_vc | ( | PSI_statement_locker * | locker | ) |
void pfs_set_statement_query_id_vc | ( | PSI_statement_locker * | locker, |
ulonglong | query_id | ||
) |
void pfs_set_statement_rows_examined_vc | ( | PSI_statement_locker * | locker, |
ulonglong | count | ||
) |
void pfs_set_statement_rows_sent_vc | ( | PSI_statement_locker * | locker, |
ulonglong | count | ||
) |
void pfs_set_statement_secondary_engine_vc | ( | PSI_statement_locker * | locker, |
bool | secondary | ||
) |
void pfs_set_statement_text_vc | ( | PSI_statement_locker * | locker, |
const char * | text, | ||
uint | text_len | ||
) |
void pfs_set_thread_account_vc | ( | const char * | user, |
int | user_len, | ||
const char * | host, | ||
int | host_len | ||
) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_command_vc | ( | int | command | ) |
Implementation of the thread instrumentation interface.
int pfs_set_thread_connect_attrs_vc | ( | const char * | buffer, |
uint | length, | ||
const void * | from_cs | ||
) |
Implementation of the thread attribute connection interface.
void pfs_set_thread_db_vc | ( | const char * | db, |
int | db_len | ||
) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_id_vc | ( | PSI_thread * | thread, |
ulonglong | processlist_id | ||
) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_info_vc | ( | const char * | info, |
uint | info_len | ||
) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_os_id_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_peer_port_vc | ( | PSI_thread * | thread, |
uint | port | ||
) |
Implementation of the thread instrumentation interface.
int pfs_set_thread_resource_group_by_id_vc | ( | PSI_thread * | thread, |
ulonglong | thread_id, | ||
const char * | group_name, | ||
int | group_name_len, | ||
void * | user_data | ||
) |
Implementation of the thread instrumentation interface.
int pfs_set_thread_resource_group_vc | ( | const char * | group_name, |
int | group_name_len, | ||
void * | user_data | ||
) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_secondary_engine_vc | ( | bool | secondary | ) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_start_time_vc | ( | time_t | start_time | ) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_state_v1 | ( | const char * | ) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_THD_vc | ( | PSI_thread * | thread, |
THD * | thd | ||
) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_user_vc | ( | const char * | user, |
int | user_len | ||
) |
Implementation of the thread instrumentation interface.
void pfs_set_thread_vc | ( | PSI_thread * | thread | ) |
Implementation of the thread instrumentation interface.
void pfs_set_transaction_gtid_v1 | ( | PSI_transaction_locker * | locker, |
const void * | sid, | ||
const void * | gtid_spec | ||
) |
void pfs_set_transaction_trxid_v1 | ( | PSI_transaction_locker * | locker, |
const ulonglong * | trxid | ||
) |
void pfs_set_transaction_xa_state_v1 | ( | PSI_transaction_locker * | locker, |
int | xa_state | ||
) |
void pfs_set_transaction_xid_v1 | ( | PSI_transaction_locker * | locker, |
const void * | xid, | ||
int | xa_state | ||
) |
void pfs_signal_cond_v1 | ( | PSI_cond * | cond | ) |
Implementation of the cond instrumentation interface.
|
static |
int pfs_spawn_thread_v4 | ( | PSI_thread_key | key, |
my_thread_handle * | thread, | ||
const my_thread_attr_t * | attr, | ||
void *(*)(void *) | start_routine, | ||
void * | arg | ||
) |
int pfs_spawn_thread_vc | ( | PSI_thread_key | key, |
PSI_thread_seqnum | seqnum, | ||
my_thread_handle * | thread, | ||
const my_thread_attr_t * | attr, | ||
void *(*)(void *) | start_routine, | ||
void * | arg | ||
) |
Implementation of the thread instrumentation interface.
PSI_cond_locker * pfs_start_cond_wait_v1 | ( | PSI_cond_locker_state * | state, |
PSI_cond * | cond, | ||
PSI_mutex * | mutex, | ||
PSI_cond_operation | op, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the cond instrumentation interface.
void pfs_start_file_close_wait_vc | ( | PSI_file_locker * | locker, |
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the file instrumentation interface.
void pfs_start_file_open_wait_vc | ( | PSI_file_locker * | locker, |
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the file instrumentation interface.
void pfs_start_file_rename_wait_vc | ( | PSI_file_locker * | locker, |
size_t | count, | ||
const char * | old_name, | ||
const char * | new_name, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the file instrumentation interface.
void pfs_start_file_wait_vc | ( | PSI_file_locker * | locker, |
size_t | count, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the file instrumentation interface.
PSI_idle_locker * pfs_start_idle_wait_v1 | ( | PSI_idle_locker_state * | state, |
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the idle instrumentation interface.
PSI_metadata_locker * pfs_start_metadata_wait_vc | ( | PSI_metadata_locker_state * | state, |
PSI_metadata_lock * | lock, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
PSI_mutex_locker * pfs_start_mutex_wait_v1 | ( | PSI_mutex_locker_state * | state, |
PSI_mutex * | mutex, | ||
PSI_mutex_operation | op, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the mutex instrumentation interface.
PSI_rwlock_locker * pfs_start_rwlock_rdwait_v2 | ( | PSI_rwlock_locker_state * | state, |
PSI_rwlock * | rwlock, | ||
PSI_rwlock_operation | op, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
|
static |
Implementation of the rwlock instrumentation interface.
PSI_rwlock_locker * pfs_start_rwlock_wrwait_v2 | ( | PSI_rwlock_locker_state * | state, |
PSI_rwlock * | rwlock, | ||
PSI_rwlock_operation | op, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
PSI_socket_locker * pfs_start_socket_wait_v1 | ( | PSI_socket_locker_state * | state, |
PSI_socket * | socket, | ||
PSI_socket_operation | op, | ||
size_t | count, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
Socket locker.
|
static |
PSI_stage_progress * pfs_start_stage_v1 | ( | PSI_stage_key | key, |
const char * | src_file, | ||
int | src_line | ||
) |
void pfs_start_statement_vc | ( | PSI_statement_locker * | locker, |
const char * | db, | ||
uint | db_len, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
PSI_table_locker * pfs_start_table_io_wait_v1 | ( | PSI_table_locker_state * | state, |
PSI_table * | table, | ||
PSI_table_io_operation | op, | ||
uint | index, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the table instrumentation interface.
PSI_table_locker * pfs_start_table_lock_wait_v1 | ( | PSI_table_locker_state * | state, |
PSI_table * | table, | ||
PSI_table_lock_operation | op, | ||
ulong | op_flags, | ||
const char * | src_file, | ||
uint | src_line | ||
) |
Implementation of the table instrumentation interface.
void pfs_start_transaction_v1 | ( | PSI_transaction_locker * | locker, |
const char * | src_file, | ||
uint | src_line | ||
) |
void pfs_statement_abort_telemetry_vc | ( | PSI_statement_locker * | locker | ) |
|
static |
void pfs_unbind_table_v1 | ( | PSI_table * | table | ) |
Implementation of the table instrumentation interface.
void pfs_unload_plugin_v1 | ( | const char * | plugin_name | ) |
Implementation of the thread instrumentation interface.
void pfs_unlock_mutex_v1 | ( | PSI_mutex * | mutex | ) |
Implementation of the mutex instrumentation interface.
void pfs_unlock_rwlock_v2 | ( | PSI_rwlock * | rwlock, |
PSI_rwlock_operation | op | ||
) |
Implementation of the rwlock instrumentation interface.
void pfs_unlock_table_v1 | ( | PSI_table * | table | ) |
void pfs_unregister_data_lock_v1 | ( | PSI_engine_data_lock_inspector * | inspector | ) |
int pfs_unregister_notification_vc | ( | int | handle | ) |
Implementation of the thread instrumentation interface.
void record_main_thread_id | ( | ) |
const mysql_service_psi_cond_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_cond_v1 | |||
) |
const mysql_service_psi_error_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_error_v1 | |||
) |
const mysql_service_psi_file_v2_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_file_v2 | |||
) |
const mysql_service_psi_idle_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_idle_v1 | |||
) |
const mysql_service_psi_mdl_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_mdl_v1 | |||
) |
const mysql_service_psi_mdl_v2_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_mdl_v2 | |||
) |
const mysql_service_psi_memory_v2_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_memory_v2 | |||
) |
const mysql_service_psi_mutex_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_mutex_v1 | |||
) |
const mysql_service_psi_rwlock_v2_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_rwlock_v2 | |||
) |
const mysql_service_psi_socket_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_socket_v1 | |||
) |
const mysql_service_psi_stage_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_stage_v1 | |||
) |
const mysql_service_psi_statement_v5_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_statement_v5 | |||
) |
const mysql_service_psi_table_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_table_v1 | |||
) |
const mysql_service_psi_thread_v4_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_thread_v4 | |||
) |
const mysql_service_psi_thread_v5_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_thread_v5 | |||
) |
const mysql_service_psi_thread_v6_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_thread_v6 | |||
) |
const mysql_service_psi_thread_v7_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_thread_v7 | |||
) |
const mysql_service_psi_tls_channel_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_tls_channel_v1 | |||
) |
const mysql_service_psi_transaction_v1_t SERVICE_IMPLEMENTATION | ( | performance_schema | , |
psi_transaction_v1 | |||
) |
int set_thread_resource_group | ( | PFS_thread * | pfs, |
const char * | group_name, | ||
int | group_name_len, | ||
void * | user_data | ||
) |
Set the resource group name for a given thread.
pfs | Thread instrumentation |
group_name | Group name |
group_name_len | Length of group_name |
user_data | Optional pointer to user-defined data |
|
inlinestatic |
|
static |
Conversion map from PSI_cond_operation to enum_operation_type.
Indexed by enum PSI_cond_operation.
|
static |
Conversion map from PSI_file_operation to enum_operation_type.
Indexed by enum PSI_file_operation.
PSI_engine_data_lock_inspector* g_data_lock_inspector[COUNT_DATA_LOCK_ENGINES] |
unsigned int g_data_lock_inspector_count = 0 |
|
static |
|
static |
Conversion map from PSI_mutex_operation to enum_operation_type.
Indexed by enum PSI_mutex_operation.
struct PSI_cond_bootstrap pfs_cond_bootstrap = {get_cond_interface} |
Entry point to the performance schema implementation.
This singleton is used to discover the performance schema services.
PSI_cond_service_v1 pfs_cond_service_v1 |
struct PSI_data_lock_bootstrap pfs_data_lock_bootstrap |
PSI_data_lock_service_v1 pfs_data_lock_service_v1 |
struct PSI_error_bootstrap pfs_error_bootstrap = {get_error_interface} |
PSI_error_service_v1 pfs_error_service_v1 |
struct PSI_file_bootstrap pfs_file_bootstrap = {get_file_interface} |
PSI_file_service_v2 pfs_file_service_v2 |
struct PSI_idle_bootstrap pfs_idle_bootstrap = {get_idle_interface} |
PSI_idle_service_v1 pfs_idle_service_v1 |
struct PSI_mdl_bootstrap pfs_mdl_bootstrap = {get_mdl_interface} |
PSI_mdl_service_v1 pfs_mdl_service_v1 |
PSI_mdl_service_v2 pfs_mdl_service_v2 |
struct PSI_memory_bootstrap pfs_memory_bootstrap = {get_memory_interface} |
PSI_memory_service_v2 pfs_memory_service_v2 |
struct PSI_mutex_bootstrap pfs_mutex_bootstrap = {get_mutex_interface} |
PSI_mutex_service_v1 pfs_mutex_service_v1 |
struct PSI_rwlock_bootstrap pfs_rwlock_bootstrap = {get_rwlock_interface} |
PSI_rwlock_service_v2 pfs_rwlock_service_v2 |
struct PSI_socket_bootstrap pfs_socket_bootstrap = {get_socket_interface} |
PSI_socket_service_v1 pfs_socket_service_v1 |
struct PSI_stage_bootstrap pfs_stage_bootstrap = {get_stage_interface} |
PSI_stage_service_v1 pfs_stage_service_v1 |
struct PSI_statement_bootstrap pfs_statement_bootstrap |
PSI_statement_service_v5 pfs_statement_service_v5 |
struct PSI_system_bootstrap pfs_system_bootstrap = {get_system_interface} |
PSI_system_service_v1 pfs_system_service_v1 |
Implementation of the instrumentation interface.
struct PSI_table_bootstrap pfs_table_bootstrap = {get_table_interface} |
PSI_table_service_v1 pfs_table_service_v1 |
struct PSI_thread_bootstrap pfs_thread_bootstrap = {get_thread_interface} |
PSI_thread_service_v4 pfs_thread_service_v4 |
Implementation of the instrumentation interface.
PSI_thread_service_v5 pfs_thread_service_v5 |
Implementation of the instrumentation interface.
PSI_thread_service_v6 pfs_thread_service_v6 |
Implementation of the instrumentation interface.
PSI_thread_service_v7 pfs_thread_service_v7 |
Implementation of the instrumentation interface.
struct PSI_tls_channel_bootstrap pfs_tls_channel_bootstrap |
PSI_tls_channel_service_v1 pfs_tls_channel_service_v1 |
struct PSI_transaction_bootstrap pfs_transaction_bootstrap |
PSI_transaction_service_v1 pfs_transaction_service_v1 |
|
static |
Conversion map from PSI_rwlock_operation to enum_operation_type.
Indexed by enum PSI_rwlock_operation.
const mysql_service_psi_tls_channel_v1_t SERVICE_IMPLEMENTATION(performance_schema, psi_tls_channel_v1) | ( | performance_schema | , |
psi_system_v1 | |||
) |
|
static |
|
static |
Conversion map from PSI_socket_operation to enum_operation_type.
Indexed by enum PSI_socket_operation.
|
staticconstexpr |
|
static |
Conversion map from PSI_table_operation to enum_operation_type.
Indexed by enum PSI_table_io_operation.
|
static |
Conversion map from enum PFS_TL_LOCK_TYPE to enum_operation_type.
Indexed by enum PFS_TL_LOCK_TYPE.
thread_local PFS_thread* THR_PFS = nullptr |
Performance schema Thread Local Storage.