33#ifndef dict0stats_bg_h
34#define dict0stats_bg_h
46#ifdef HAVE_PSI_INTERFACE
74 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:33
os_event_t dict_stats_event
Event to wake up the stats thread.
Definition: dict0stats_bg.cc:58
void dict_stats_thread()
This is the thread for background stats gathering.
Definition: dict0stats_bg.cc:355
void dict_stats_recalc_pool_del(const dict_table_t *table)
Delete a given table from the auto recalc pool.
Definition: dict0stats_bg.cc:167
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:72
void dict_stats_thread_init()
Initialize global variables needed for the operation of dict_stats_thread().
Definition: dict0stats_bg.cc:209
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:334
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:62
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:237
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:197
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:117
mysql_pfs_key_t dict_stats_recalc_pool_mutex_key
void dict_stats_shutdown()
Shutdown the dict stats thread.
Definition: dict0stats_bg.cc:390
Code used for background table and index stats gathering.
Data dictionary global types.
static PFS_engine_table_share_proxy table
Definition: pfs.cc:60
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:2711
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:2697
Data structure for a database table.
Definition: dict0mem.h:1908
Define for performance schema registration key.
Definition: sync0sync.h:50
InnoDB condition variable.
Definition: os0event.cc:62
Definition: trx0trx.h:685
Version control for database, common definitions, and include files.