24#ifndef PFS_ENGINE_TABLE_H
25#define PFS_ENGINE_TABLE_H
77 unsigned char *new_buf,
Field **fields);
89 virtual int rnd_init(
bool scan [[maybe_unused]]) {
return 0; }
95 bool sorted [[maybe_unused]]) {
105 uint key_len [[maybe_unused]]) {
152 unsigned char *new_buf,
Field **fields);
187 unsigned char *
buf,
Field **fields);
211 bool &isnull,
uchar *value);
214 bool &isnull,
short *value);
217 bool &isnull, ushort *value);
220 bool &isnull,
long *value);
223 bool &isnull, ulong *value);
229 bool &isnull, ulong *value);
242 bool &isnull,
char *
buffer,
244 uint buffer_capacity);
247 bool &isnull,
char *
buffer,
249 uint buffer_capacity);
367 Field **fields)
const;
440 bool any_combination_will_do)
const override;
458 bool any_combination_will_do)
const override;
476 bool any_combination_will_do)
const override;
494 bool any_combination_will_do)
const override;
511 bool any_combination_will_do)
const override;
527 bool any_combination_will_do)
const override;
543 bool any_combination_will_do)
const override;
559 bool any_combination_will_do)
const override;
uint32_t Access_bitmask
Definition: auth_acls.h:34
ACL_internal_access_result
Definition: auth_common.h:85
Per internal table ACL access rules.
Definition: auth_common.h:107
uint8 type
Definition: key.h:73
Definition: sql_list.h:434
A class to keep list of table shares for non-native performance schema tables i.e.
Definition: pfs_engine_table.h:399
void lock_share_list()
Definition: pfs_engine_table.h:407
mysql_mutex_t LOCK_pfs_share_list
Definition: pfs_engine_table.h:422
void add_share(PFS_engine_table_share *share)
Definition: pfs_engine_table.h:411
PFS_dynamic_table_shares()=default
std::vector< PFS_engine_table_share * > shares_vector
Definition: pfs_engine_table.h:421
void unlock_share_list()
Definition: pfs_engine_table.h:409
Privileges for editable tables.
Definition: pfs_engine_table.h:486
PFS_editable_acl()=default
~PFS_editable_acl() override=default
Definition: pfs_engine_table.h:284
uint m_fields
Definition: pfs_engine_table.h:296
KEY * m_key_info
Definition: pfs_engine_table.h:297
void set_key_info(KEY *key_info)
Definition: pfs_engine_table.h:290
PFS_engine_index_abstract()=default
virtual ~PFS_engine_index_abstract()=default
virtual void read_key(const uchar *key, uint key_len, enum ha_rkey_function find_flag)=0
Definition: pfs_engine_table.h:300
PFS_engine_index(PFS_engine_key *key_1, PFS_engine_key *key_2, PFS_engine_key *key_3, PFS_engine_key *key_4)
Definition: pfs_engine_table.h:324
PFS_engine_key * m_key_ptr_2
Definition: pfs_engine_table.h:347
PFS_engine_key * m_key_ptr_4
Definition: pfs_engine_table.h:349
PFS_engine_index(PFS_engine_key *key_1, PFS_engine_key *key_2)
Definition: pfs_engine_table.h:309
~PFS_engine_index() override=default
PFS_engine_index(PFS_engine_key *key_1, PFS_engine_key *key_2, PFS_engine_key *key_3, PFS_engine_key *key_4, PFS_engine_key *key_5)
Definition: pfs_engine_table.h:332
PFS_engine_key * m_key_ptr_5
Definition: pfs_engine_table.h:350
PFS_engine_index(PFS_engine_key *key_1, PFS_engine_key *key_2, PFS_engine_key *key_3)
Definition: pfs_engine_table.h:316
PFS_engine_key * m_key_ptr_3
Definition: pfs_engine_table.h:348
PFS_engine_key * m_key_ptr_1
Definition: pfs_engine_table.h:346
PFS_engine_index(PFS_engine_key *key_1)
Definition: pfs_engine_table.h:302
Definition: pfs_engine_table.h:268
virtual ~PFS_engine_key()=default
virtual void read(PFS_key_reader &reader, enum ha_rkey_function find_flag)=0
const char * m_name
Definition: pfs_engine_table.h:277
PFS_engine_key(const char *name)
Definition: pfs_engine_table.h:270
bool m_is_null
Definition: pfs_engine_table.h:281
enum ha_rkey_function m_find_flag
Definition: pfs_engine_table.h:280
An abstract PERFORMANCE_SCHEMA table.
Definition: pfs_engine_table.h:70
virtual int index_prev()
Definition: pfs_engine_table.h:113
virtual int read_row_values(TABLE *table, unsigned char *buf, Field **fields, bool read_all)=0
Read the current row values.
PFS_engine_index_abstract * m_index
Current index.
Definition: pfs_engine_table.h:180
virtual int rnd_init(bool scan)
Initialize table scan.
Definition: pfs_engine_table.h:89
virtual int rnd_pos(const void *pos)=0
Fetch a row by position.
virtual int rnd_next()=0
Fetch the next row in this cursor.
virtual void reset_position()=0
Reset the cursor position to the beginning of the table.
virtual int index_last()
Definition: pfs_engine_table.h:117
time_normalizer * m_normalizer
Current normalizer.
Definition: pfs_engine_table.h:178
virtual int index_init(uint idx, bool sorted)
Definition: pfs_engine_table.h:94
void * m_pos_ptr
Opaque pointer to the m_pos position of this cursor.
Definition: pfs_engine_table.h:176
virtual int index_next()
Find key in index, read record.
Definition: pfs_engine_table.h:110
virtual ~PFS_engine_table()=default
Destructor.
virtual int index_first()
Definition: pfs_engine_table.h:115
virtual int index_read_last(KEY *key_infos, const uchar *key, uint key_len)
Definition: pfs_engine_table.h:103
const PFS_engine_table_share * m_share_ptr
Table share.
Definition: pfs_engine_table.h:174
PFS_engine_table(const PFS_engine_table_share *share, void *pos)
Constructor.
Definition: pfs_engine_table.h:167
Privileges for read only tables.
Definition: pfs_engine_table.h:432
~PFS_readonly_acl() override=default
PFS_readonly_acl()=default
Privileges for readable processlist tables.
Definition: pfs_engine_table.h:552
~PFS_readonly_processlist_acl() override=default
PFS_readonly_processlist_acl()=default
Privileges for world readable tables.
Definition: pfs_engine_table.h:520
~PFS_readonly_world_acl() override=default
PFS_readonly_world_acl()=default
Privileges for truncatable tables.
Definition: pfs_engine_table.h:450
PFS_truncatable_acl()=default
~PFS_truncatable_acl() override=default
Privileges for world readable truncatable tables.
Definition: pfs_engine_table.h:536
PFS_truncatable_world_acl()=default
~PFS_truncatable_world_acl() override=default
Privileges for unknown tables.
Definition: pfs_engine_table.h:503
PFS_unknown_acl()=default
~PFS_unknown_acl() override=default
Privileges for updatable tables.
Definition: pfs_engine_table.h:468
~PFS_updatable_acl() override=default
PFS_updatable_acl()=default
Class to hold information regarding a table to be created on behalf of a plugin.
Definition: plugin_table.h:40
#define mysql_mutex_lock(M)
Definition: mysql_mutex.h:50
#define mysql_mutex_unlock(M)
Definition: mysql_mutex.h:57
Fido Client Authentication nullptr
Definition: fido_client_plugin.cc:222
static const std::string dec("DECRYPTION")
#define mysql_mutex_assert_owner(M)
Wrapper, to use safe_mutex_assert_owner with instrumented mutexes.
Definition: mysql_mutex.h:112
mysql_service_pfs_plugin_table_v1_t * pfs_table
Definition: log0pfs.cc:47
This file includes constants used by all storage engines.
ha_base_keytype
Definition: my_base.h:439
#define HA_ERR_UNSUPPORTED
unsupported extension used
Definition: my_base.h:854
ha_rkey_function
Definition: my_base.h:78
my_off_t ha_rows
Definition: my_base.h:1140
Header for compiler-dependent features.
Some integer typedefs for easier portability.
unsigned long long int ulonglong
Definition: my_inttypes.h:56
unsigned char uchar
Definition: my_inttypes.h:52
long long int longlong
Definition: my_inttypes.h:55
ABI for instrumented mutexes.
Definition: buf0block_hint.cc:30
PT & ref(PT *tp)
Definition: tablespace_impl.cc:359
mutable_buffer buffer(void *p, size_t n) noexcept
Definition: buffer.h:420
const char * table_name
Definition: rules_table_service.cc:56
Instrumentation helpers for mutexes.
required string key
Definition: replication_asynchronous_connection_failover.proto:60
case opt name
Definition: sslopt-case.h:33
Performance schema instrumentation (declarations).
Position of a double cursor, for iterations using 2 nested loops.
Definition: pfs_engine_table.h:601
void set_after(const PFS_double_index *other)
Set this index after a given position.
Definition: pfs_engine_table.h:636
void set_at(uint index_1, uint index_2)
Set this index at a given position.
Definition: pfs_engine_table.h:618
PFS_double_index(uint index_1, uint index_2)
Constructor.
Definition: pfs_engine_table.h:612
uint m_index_1
Outer index.
Definition: pfs_engine_table.h:603
void set_at(const PFS_double_index *other)
Set this index at a given position.
Definition: pfs_engine_table.h:627
uint m_index_2
Current index within index_1.
Definition: pfs_engine_table.h:605
A structure to keep callback functions to be implemented by plugin/component.
Definition: pfs_plugin_table_service.h:413
A PERFORMANCE_SCHEMA table share.
Definition: pfs_engine_table.h:358
PFS_engine_table_proxy m_st_table
Definition: pfs_engine_table.h:388
std::atomic< int > m_ref_count
Definition: pfs_engine_table.h:390
bool m_in_purgatory
Definition: pfs_engine_table.h:392
const Plugin_table * m_table_def
Table definition.
Definition: pfs_engine_table.h:383
const ACL_internal_table_access * m_acl
Table Access Control List.
Definition: pfs_engine_table.h:369
pfs_write_row_t m_write_row
Write row function.
Definition: pfs_engine_table.h:373
uint m_ref_length
Length of the m_pos position structure.
Definition: pfs_engine_table.h:379
pfs_delete_all_rows_t m_delete_all_rows
Delete all rows function.
Definition: pfs_engine_table.h:375
pfs_get_row_count_t m_get_row_count
Get rows count function.
Definition: pfs_engine_table.h:377
THR_LOCK * m_thr_lock_ptr
The lock, stored on behalf of the SQL layer.
Definition: pfs_engine_table.h:381
pfs_open_table_t m_open_table
Open table function.
Definition: pfs_engine_table.h:371
bool m_perpetual
Table is available even if the Performance Schema is disabled.
Definition: pfs_engine_table.h:385
PFS_key_reader: Convert key into internal format.
Definition: pfs_engine_table.h:196
uint m_parts_found
Definition: pfs_engine_table.h:265
PFS_key_reader(const KEY *key_info, const uchar *key, uint key_len)
Definition: pfs_engine_table.h:197
const KEY_PART_INFO * m_remaining_key_part_info
Definition: pfs_engine_table.h:260
ha_base_keytype get_key_type()
Definition: pfs_engine_table.h:251
const KEY * m_key_info
Definition: pfs_engine_table.h:256
uint m_remaining_key_len
Definition: pfs_engine_table.h:262
const uchar * m_remaining_key
Definition: pfs_engine_table.h:261
const uchar * m_key
Definition: pfs_engine_table.h:258
uint m_key_len
Definition: pfs_engine_table.h:259
const KEY_PART_INFO * m_key_part_info
Definition: pfs_engine_table.h:257
Position of a cursor, for simple iterations.
Definition: pfs_engine_table.h:566
PFS_simple_index(uint index)
Constructor.
Definition: pfs_engine_table.h:574
void set_at(const PFS_simple_index *other)
Set this index at a given position.
Definition: pfs_engine_table.h:586
void set_at(uint index)
Set this index at a given position.
Definition: pfs_engine_table.h:580
void set_after(const PFS_simple_index *other)
Set this index after a given position.
Definition: pfs_engine_table.h:592
void next()
Set this index to the next record.
Definition: pfs_engine_table.h:597
uint m_index
Current row index.
Definition: pfs_engine_table.h:568
Position of a triple cursor, for iterations using 3 nested loops.
Definition: pfs_engine_table.h:643
void set_at(const PFS_triple_index *other)
Set this index at a given position.
Definition: pfs_engine_table.h:673
uint m_index_3
Current index within index_2.
Definition: pfs_engine_table.h:649
uint m_index_2
Current index within index_1.
Definition: pfs_engine_table.h:647
PFS_triple_index(uint index_1, uint index_2, uint index_3)
Constructor.
Definition: pfs_engine_table.h:657
void set_after(const PFS_triple_index *other)
Set this index after a given position.
Definition: pfs_engine_table.h:683
uint m_index_1
Outer index.
Definition: pfs_engine_table.h:645
void set_at(uint index_1, uint index_2, uint index_3)
Set this index at a given position.
Definition: pfs_engine_table.h:663
Definition: thr_lock.h:139
An instrumented mutex structure.
Definition: mysql_mutex_bits.h:50
A time normalizer.
Definition: pfs_timer.h:119
unsigned int uint
Definition: uca9-dump.cc:75