34#ifndef dict0stats_bg_h
35#define dict0stats_bg_h
47#ifdef HAVE_PSI_INTERFACE
75 std::this_thread::sleep_for(std::chrono::milliseconds(250));
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:36
os_event_t dict_stats_event
Event to wake up the stats thread.
Definition: dict0stats_bg.cc:60
void dict_stats_thread()
This is the thread for background stats gathering.
Definition: dict0stats_bg.cc:382
void dict_stats_recalc_pool_del(const dict_table_t *table)
Delete a given table from the auto recalc pool.
Definition: dict0stats_bg.cc:169
static void DICT_STATS_BG_YIELD(trx_t *trx, ut::Location location)
Yield the data dictionary latch when waiting for the background thread to stop accessing a table.
Definition: dict0stats_bg.h:73
void dict_stats_thread_init()
Initialize global variables needed for the operation of dict_stats_thread().
Definition: dict0stats_bg.cc:211
void dict_stats_disabled_debug_update(THD *thd, SYS_VAR *var, void *var_ptr, const void *save)
Disables dict stats thread.
Definition: dict0stats_bg.cc:361
static bool dict_stats_stop_bg(dict_table_t *table)
Request the background collection of statistics to stop for a table.
bool innodb_dict_stats_disabled_debug
Value of MySQL global used to disable dict_stats thread.
Definition: dict0stats_bg.cc:64
void dict_stats_thread_deinit()
Free resources allocated by dict_stats_thread_init(), must be called after dict_stats_thread() has ex...
Definition: dict0stats_bg.cc:239
void dict_stats_wait_bg_to_stop_using_table(dict_table_t *table, trx_t *trx)
Wait until background stats thread has stopped using the specified table.
Definition: dict0stats_bg.cc:199
void dict_stats_recalc_pool_add(const dict_table_t *table)
Add a table to the recalc pool, which is processed by the background stats gathering thread.
Definition: dict0stats_bg.cc:119
mysql_pfs_key_t dict_stats_recalc_pool_mutex_key
void dict_stats_shutdown()
Shutdown the dict stats thread.
Definition: dict0stats_bg.cc:417
Code used for background table and index stats gathering.
Data dictionary global types.
static PFS_engine_table_share_proxy table
Definition: pfs.cc:61
The interface to the operating system condition variables.
The interface to the operating system process and thread control primitives.
Interface between Innobase row operations and MySQL.
void row_mysql_unlock_data_dictionary(trx_t *trx)
Unlocks the data dictionary exclusive lock.
Definition: row0mysql.cc:2707
void row_mysql_lock_data_dictionary(trx_t *trx, ut::Location location)
Locks the data dictionary exclusively for performing a table create or other data dictionary modifica...
Definition: row0mysql.cc:2693
Data structure for a database table.
Definition: dict0mem.h:1909
Define for performance schema registration key.
Definition: sync0sync.h:51
InnoDB condition variable.
Definition: os0event.cc:63
Definition: trx0trx.h:684
Version control for database, common definitions, and include files.