MySQL 8.0.39
Source Code Documentation
pfs_example_machine.cc File Reference

Functions

PSI_table_handlemachine_open_table (PSI_pos **pos)
 Instantiate Machine_Table_Handle at plugin code when corresponding table in performance schema is opened. More...
 
void machine_close_table (PSI_table_handle *handle)
 Destroy the Machine_Table_Handle at plugin code when corresponding table in performance schema is closed. More...
 
static void copy_record (Machine_Record *dest, Machine_Record *source)
 
int machine_rnd_next (PSI_table_handle *handle)
 
int machine_rnd_init (PSI_table_handle *h, bool scan)
 
int machine_rnd_pos (PSI_table_handle *handle)
 
int machine_index_init (PSI_table_handle *handle, uint idx, bool sorted, PSI_index_handle **index)
 
int machine_index_read (PSI_index_handle *index, PSI_key_reader *reader, unsigned int idx, int find_flag)
 
int machine_index_next (PSI_table_handle *handle)
 
void machine_reset_position (PSI_table_handle *handle)
 
int machine_read_column_value (PSI_table_handle *handle, PSI_field *field, uint index)
 
int machine_write_row_values (PSI_table_handle *handle)
 
int machine_write_column_value (PSI_table_handle *handle, PSI_field *field, unsigned int index)
 
int machine_update_row_values (PSI_table_handle *handle)
 
int machine_update_column_value (PSI_table_handle *handle, PSI_field *field, unsigned int index)
 
int machine_delete_row_values (PSI_table_handle *handle)
 
int machine_delete_all_rows (void)
 
unsigned long long machine_get_row_count (void)
 
void init_machine_share (PFS_engine_table_share_proxy *share)
 

Variables

PFS_engine_table_share_proxy machine_st_share
 
mysql_mutex_t LOCK_machine_records_array
 
unsigned int machine_rows_in_table = 0
 
std::vector< Machine_Recordmachine_records_vector
 An array to keep rows of the tables. More...
 

Function Documentation

◆ copy_record()

static void copy_record ( Machine_Record dest,
Machine_Record source 
)
static

◆ init_machine_share()

void init_machine_share ( PFS_engine_table_share_proxy share)

◆ machine_close_table()

void machine_close_table ( PSI_table_handle handle)

Destroy the Machine_Table_Handle at plugin code when corresponding table in performance schema is closed.

◆ machine_delete_all_rows()

int machine_delete_all_rows ( void  )

◆ machine_delete_row_values()

int machine_delete_row_values ( PSI_table_handle handle)

◆ machine_get_row_count()

unsigned long long machine_get_row_count ( void  )

◆ machine_index_init()

int machine_index_init ( PSI_table_handle handle,
uint  idx,
bool  sorted,
PSI_index_handle **  index 
)

◆ machine_index_next()

int machine_index_next ( PSI_table_handle handle)

◆ machine_index_read()

int machine_index_read ( PSI_index_handle index,
PSI_key_reader reader,
unsigned int  idx,
int  find_flag 
)

◆ machine_open_table()

PSI_table_handle * machine_open_table ( PSI_pos **  pos)

Instantiate Machine_Table_Handle at plugin code when corresponding table in performance schema is opened.

◆ machine_read_column_value()

int machine_read_column_value ( PSI_table_handle handle,
PSI_field field,
uint  index 
)

◆ machine_reset_position()

void machine_reset_position ( PSI_table_handle handle)

◆ machine_rnd_init()

int machine_rnd_init ( PSI_table_handle h,
bool  scan 
)

◆ machine_rnd_next()

int machine_rnd_next ( PSI_table_handle handle)

◆ machine_rnd_pos()

int machine_rnd_pos ( PSI_table_handle handle)

◆ machine_update_column_value()

int machine_update_column_value ( PSI_table_handle handle,
PSI_field field,
unsigned int  index 
)

◆ machine_update_row_values()

int machine_update_row_values ( PSI_table_handle handle)

◆ machine_write_column_value()

int machine_write_column_value ( PSI_table_handle handle,
PSI_field field,
unsigned int  index 
)

◆ machine_write_row_values()

int machine_write_row_values ( PSI_table_handle handle)

Variable Documentation

◆ LOCK_machine_records_array

mysql_mutex_t LOCK_machine_records_array

◆ machine_records_vector

std::vector<Machine_Record> machine_records_vector

An array to keep rows of the tables.

When a row is inserted in plugin table, it will be stored here. When a row is queried from plugin table, it will be fetched from here.

◆ machine_rows_in_table

unsigned int machine_rows_in_table = 0

◆ machine_st_share

PFS_engine_table_share_proxy machine_st_share