24#ifndef HA_PERFSCHEMA_H
25#define HA_PERFSCHEMA_H
120 [[maybe_unused]])
const override {
150 int close()
override;
app_data_ptr new_data(u_int n, char *val, cons_type consensus)
An abstract PERFORMANCE_SCHEMA table.
Definition: pfs_engine_table.h:70
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:34
A handler for a PERFORMANCE_SCHEMA table.
Definition: ha_perfschema.h:56
void use_hidden_primary_key() override
use_hidden_primary_key() is called in case of an update/delete when (table_flags() and HA_PRIMARY_KEY...
Definition: ha_perfschema.cc:1645
ulong index_flags(uint idx, uint part, bool all_parts) const override
Operations supported by indexes.
Definition: ha_perfschema.cc:1867
uint max_supported_record_length() const override
Definition: ha_perfschema.h:109
int open(const char *name, int mode, uint test_if_locked, const dd::Table *table_def) override
Open a performance schema table.
Definition: ha_perfschema.cc:1589
THR_LOCK_DATA m_thr_lock
MySQL lock.
Definition: ha_perfschema.h:255
enum ha_key_alg get_default_index_algorithm() const override
Get default key algorithm for SE.
Definition: ha_perfschema.h:105
int rename_table(const char *from, const char *to, const dd::Table *from_table_def, dd::Table *to_table_def) override
Default rename_table() and delete_table() rename/delete files with a given name and extensions from h...
Definition: ha_perfschema.cc:1805
int index_end() override
Definition: ha_perfschema.cc:1917
PFS_engine_table_share * m_table_share
Performance schema table share for this table handler.
Definition: ha_perfschema.h:257
void position(const uchar *record) override
Read the row current position.
Definition: ha_perfschema.cc:1733
THR_LOCK_DATA ** store_lock(THD *thd, THR_LOCK_DATA **to, enum thr_lock_type lock_type) override
Is not invoked for non-transactional temporary tables.
Definition: ha_perfschema.cc:1790
int delete_row(const uchar *buf) override
Delete a row.
Definition: ha_perfschema.cc:1672
~ha_perfschema() override
int truncate(dd::Table *table_def) override
Quickly remove all rows from a table.
Definition: ha_perfschema.cc:1788
int delete_all_rows() override
Delete all rows in a table.
Definition: ha_perfschema.cc:1767
ha_rows estimate_rows_upper_bound() override
Return upper bound of current number of records in the table (max.
Definition: ha_perfschema.h:131
int index_read(uchar *buf, const uchar *key, uint key_len, enum ha_rkey_function find_flag) override
Positions an index cursor to the index specified in the handle.
Definition: ha_perfschema.cc:1932
double scan_time() override
Definition: ha_perfschema.h:133
uint max_supported_key_length() const override
Definition: ha_perfschema.h:117
int rnd_end() override
Scan end.
Definition: ha_perfschema.cc:1706
const char * index_type(uint key_number)
Definition: ha_perfschema.cc:1865
ulonglong table_flags() const override
Capabilities of the performance schema tables.
Definition: ha_perfschema.h:74
int create(const char *name, TABLE *table_arg, HA_CREATE_INFO *create_info, dd::Table *table_def) override
Create table (implementation).
Definition: ha_perfschema.cc:1811
uint max_supported_key_parts() const override
Definition: ha_perfschema.h:115
int delete_table(const char *from, const dd::Table *table_def) override
Delete a table.
Definition: ha_perfschema.cc:1800
int info(uint) override
General method to gather info from handler.
Definition: ha_perfschema.cc:1755
int rnd_init(bool scan) override
rnd_init() can be called two times without rnd_end() in between (it only makes sense if scan=1).
Definition: ha_perfschema.cc:1684
int index_next_same(uchar *buf, const uchar *key, uint keylen) override
Reads the next row matching the given key value.
Definition: ha_perfschema.cc:1990
uint max_supported_key_part_length(HA_CREATE_INFO *create_info) const override
Definition: ha_perfschema.h:119
int rnd_pos(uchar *buf, uchar *pos) override
Iterator, fetch the row at a given position.
Definition: ha_perfschema.cc:1740
int index_init(uint idx, bool sorted) override
Initializes a handle to use an index.
Definition: ha_perfschema.cc:1893
ha_perfschema(handlerton *hton, TABLE_SHARE *share)
Create a new performance schema table handle on a table.
Definition: ha_perfschema.cc:1584
int update_row(const uchar *old_data, uchar *new_data) override
Update a row.
Definition: ha_perfschema.cc:1655
void print_error(int error, myf errflags) override
Print error that we got from handler function.
Definition: ha_perfschema.cc:1836
int write_row(uchar *buf) override
Write a row.
Definition: ha_perfschema.cc:1628
uint max_supported_keys() const override
Definition: ha_perfschema.h:113
int close() override
Close a table handle.
Definition: ha_perfschema.cc:1613
const char * table_type() const override
The following can be called without an open handler.
Definition: ha_perfschema.h:67
const char ** bas_ext() const
int index_next(uchar *buf) override
Reads the next row from a cursor, which must have previously been positioned by index_read.
Definition: ha_perfschema.cc:1969
int rnd_next(uchar *buf) override
Iterator, fetch the next row.
Definition: ha_perfschema.cc:1714
bool is_executed_by_slave() const
Check if the caller is a replication thread or the caller is called by a client thread executing base...
Definition: ha_perfschema.cc:2008
PFS_engine_table * m_table
Performance schema table cursor.
Definition: ha_perfschema.h:259
The handler class is the interface for dynamically loadable storage engines.
Definition: handler.h:4412
A table definition from the master.
Definition: rpl_utility.h:248
This file includes constants used by all storage engines.
ha_key_alg
Definition: my_base.h:97
@ HA_KEY_ALG_HASH
Definition: my_base.h:109
ha_rkey_function
Definition: my_base.h:78
my_off_t ha_rows
Definition: my_base.h:1140
#define HA_POS_ERROR
Definition: my_base.h:1142
#define HA_NULL_PART_KEY
Some key part is nullable.
Definition: my_base.h:496
Some integer typedefs for easier portability.
int myf
Definition: my_inttypes.h:94
unsigned long long int ulonglong
Definition: my_inttypes.h:56
unsigned char uchar
Definition: my_inttypes.h:52
static int record
Definition: mysqltest.cc:188
Definition: buf0block_hint.cc:30
The version of the current data dictionary table definitions.
Definition: dictionary_client.h:43
mode
Definition: file_handle.h:60
required string key
Definition: replication_asynchronous_connection_failover.proto:60
#define HA_MAX_REC_LENGTH
Definition: handler.h:617
#define HA_PRIMARY_KEY_REQUIRED_FOR_DELETE
Definition: handler.h:297
#define HA_NO_TRANSACTIONS
Definition: handler.h:210
#define HA_NULL_IN_KEY
Definition: handler.h:245
#define HA_NO_AUTO_INCREMENT
Definition: handler.h:314
File containing constants that can be used throughout the server.
constexpr const unsigned int MAX_KEY
Definition: sql_const.h:45
constexpr const unsigned int MAX_REF_PARTS
Definition: sql_const.h:46
constexpr const unsigned int MAX_KEY_LENGTH
Definition: sql_const.h:47
case opt name
Definition: sslopt-case.h:33
Struct to hold information about the table that should be created.
Definition: handler.h:3045
A PERFORMANCE_SCHEMA table share.
Definition: pfs_engine_table.h:359
This structure is shared between different table objects.
Definition: table.h:690
Definition: thr_lock.h:124
handlerton is a singleton structure - one instance per storage engine - to provide access to storage ...
Definition: handler.h:2622
thr_lock_type
Definition: thr_lock.h:51
unsigned int uint
Definition: uca9-dump.cc:75