> For the complete documentation index, see [llms.txt](https://mariadb.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mariadb.com/docs/server/reference/plugins/api-plugin/api.md).

# API Reference

Every generated Plugin API class, macro, typedef, and function on one page, including the plugin services and the audit, authentication, and encryption plugin interfaces.

## Groups

| Name                                                                                                  | Description |
| ----------------------------------------------------------------------------------------------------- | ----------- |
| [`Instrumentation Interface`](/docs/server/reference/plugins/api-plugin/instrumentation_interface.md) |             |

## Classes

| Name                                                                              | Description                                                                                                                                                                                                                                                       |
| --------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [`opaque_THD`](#opaque_thd)                                                       |                                                                                                                                                                                                                                                                   |
| [`st_mysql_xid`](#st_mysql_xid)                                                   | struct [st\_mysql\_xid](#st_mysql_xid) is binary compatible with the XID structure as in the X/Open CAE Specification, Distributed Transaction Processing: The XA Specification, X/Open Company Ltd., 1991. <http://www.opengroup.org/bookstore/catalog/c193.htm> |
| [`st_mysql_auth`](#st_mysql_auth)                                                 | Server authentication plugin descriptor                                                                                                                                                                                                                           |
| [`st_plugin_vio`](#st_plugin_vio)                                                 | Provides plugin access to communication channel                                                                                                                                                                                                                   |
| [`sql_service_st`](#sql_service_st)                                               |                                                                                                                                                                                                                                                                   |
| [`st_mysql_audit`](#st_mysql_audit)                                               |                                                                                                                                                                                                                                                                   |
| [`st_mysql_value`](#st_mysql_value)                                               |                                                                                                                                                                                                                                                                   |
| [`thd_service_st`](#thd_service_st)                                               |                                                                                                                                                                                                                                                                   |
| [`json_service_st`](#json_service_st)                                             |                                                                                                                                                                                                                                                                   |
| [`st_maria_plugin`](#st_maria_plugin)                                             | MariaDB extension for plugins declaration structure.                                                                                                                                                                                                              |
| [`st_mysql_daemon`](#st_mysql_daemon)                                             |                                                                                                                                                                                                                                                                   |
| [`st_mysql_plugin`](#st_mysql_plugin)                                             | Plugin description structure.                                                                                                                                                                                                                                     |
| [`Mysql_replication`](#mysql_replication)                                         | Replication plugin descriptor                                                                                                                                                                                                                                     |
| [`wsrep_service_st`](#wsrep_service_st)                                           |                                                                                                                                                                                                                                                                   |
| [`base64_service_st`](#base64_service_st)                                         |                                                                                                                                                                                                                                                                   |
| [`logger_service_st`](#logger_service_st)                                         |                                                                                                                                                                                                                                                                   |
| [`mysql_event_table`](#mysql_event_table)                                         |                                                                                                                                                                                                                                                                   |
| [`st_mysql_ftparser`](#st_mysql_ftparser)                                         |                                                                                                                                                                                                                                                                   |
| [`my_md5_service_st`](#my_md5_service_st)                                         |                                                                                                                                                                                                                                                                   |
| [`st_mysql_show_var`](#st_mysql_show_var)                                         |                                                                                                                                                                                                                                                                   |
| [`my_sha1_service_st`](#my_sha1_service_st)                                       |                                                                                                                                                                                                                                                                   |
| [`my_sha2_service_st`](#my_sha2_service_st)                                       |                                                                                                                                                                                                                                                                   |
| [`mysql_event_general`](#mysql_event_general)                                     |                                                                                                                                                                                                                                                                   |
| [`st_plugin_vio_info`](#st_plugin_vio_info)                                       |                                                                                                                                                                                                                                                                   |
| [`thd_mdl_service_st`](#thd_mdl_service_st)                                       |                                                                                                                                                                                                                                                                   |
| [`thd_rnd_service_st`](#thd_rnd_service_st)                                       |                                                                                                                                                                                                                                                                   |
| [`my_crypt_service_st`](#my_crypt_service_st)                                     |                                                                                                                                                                                                                                                                   |
| [`st_encryption_scheme`](#st_encryption_scheme)                                   |                                                                                                                                                                                                                                                                   |
| [`st_mysql_lex_string`](#st_mysql_lex_string)                                     |                                                                                                                                                                                                                                                                   |
| [`thd_wait_service_st`](#thd_wait_service_st)                                     |                                                                                                                                                                                                                                                                   |
| [`encryption_service_st`](#encryption_service_st)                                 |                                                                                                                                                                                                                                                                   |
| [`st_mariadb_encryption`](#st_mariadb_encryption)                                 | Encryption plugin descriptor                                                                                                                                                                                                                                      |
| [`thd_alloc_service_st`](#thd_alloc_service_st)                                   |                                                                                                                                                                                                                                                                   |
| [`mysql_event_connection`](#mysql_event_connection)                               |                                                                                                                                                                                                                                                                   |
| [`my_snprintf_service_st`](#my_snprintf_service_st)                               |                                                                                                                                                                                                                                                                   |
| [`st_mysql_client_plugin`](#st_mysql_client_plugin)                               |                                                                                                                                                                                                                                                                   |
| [`thd_autoinc_service_st`](#thd_autoinc_service_st)                               |                                                                                                                                                                                                                                                                   |
| [`st_mysql_ftparser_param`](#st_mysql_ftparser_param)                             |                                                                                                                                                                                                                                                                   |
| [`st_mysql_storage_engine`](#st_mysql_storage_engine)                             |                                                                                                                                                                                                                                                                   |
| [`thd_timezone_service_st`](#thd_timezone_service_st)                             |                                                                                                                                                                                                                                                                   |
| [`st_encryption_scheme_key`](#st_encryption_scheme_key)                           |                                                                                                                                                                                                                                                                   |
| [`thd_specifics_service_st`](#thd_specifics_service_st)                           |                                                                                                                                                                                                                                                                   |
| [`kill_statement_service_st`](#kill_statement_service_st)                         |                                                                                                                                                                                                                                                                   |
| [`my_print_error_service_st`](#my_print_error_service_st)                         |                                                                                                                                                                                                                                                                   |
| [`progress_report_service_st`](#progress_report_service_st)                       |                                                                                                                                                                                                                                                                   |
| [`st_mysql_const_lex_string`](#st_mysql_const_lex_string)                         |                                                                                                                                                                                                                                                                   |
| [`st_mysql_server_auth_info`](#st_mysql_server_auth_info)                         | Provides server plugin access to authentication information                                                                                                                                                                                                       |
| [`print_check_msg_service_st`](#print_check_msg_service_st)                       |                                                                                                                                                                                                                                                                   |
| [`st_mysql_information_schema`](#st_mysql_information_schema)                     |                                                                                                                                                                                                                                                                   |
| [`encryption_scheme_service_st`](#encryption_scheme_service_st)                   |                                                                                                                                                                                                                                                                   |
| [`thd_log_warnings_service_st`](#thd_log_warnings_service_st)                     |                                                                                                                                                                                                                                                                   |
| [`thd_error_context_service_st`](#thd_error_context_service_st)                   |                                                                                                                                                                                                                                                                   |
| [`st_mariadb_password_validation`](#st_mariadb_password_validation)               | Password validation plugin descriptor                                                                                                                                                                                                                             |
| [`st_mysql_ftparser_boolean_info`](#st_mysql_ftparser_boolean_info)               |                                                                                                                                                                                                                                                                   |
| [`st_mysql_client_plugin_AUTHENTICATION`](#st_mysql_client_plugin_authentication) |                                                                                                                                                                                                                                                                   |

## Macros

***

### psi\_likely

```cpp
#define psi_likely(A) unlikely(A)
```

Defined in psi/psi.h:47

***

### psi\_unlikely

```cpp
#define psi_unlikely(A) likely(A)
```

Defined in psi/psi.h:48

***

### PSI\_SCHEMA\_NAME\_LEN

```cpp
#define PSI_SCHEMA_NAME_LEN (64 * 3)
```

Defined in psi/psi.h:1198

***

### PSI\_DYNAMIC\_CALL

```cpp
#define PSI_DYNAMIC_CALL(M, M) PSI_server->M
```

Defined in psi/psi.h:3028

***

### MYSQL\_DLLEXPORT

```cpp
#define MYSQL_DLLEXPORT
```

Defined in plugin.h:39

***

### MYSQL\_PLUGIN\_EXPORT

```cpp
#define MYSQL_PLUGIN_EXPORT MYSQL_DLLEXPORT
```

Defined in plugin.h:45

***

### MYSQL\_XIDDATASIZE

```cpp
#define MYSQL_XIDDATASIZE 128
```

Defined in plugin.h:62

***

### MYSQL\_PLUGIN\_INTERFACE\_VERSION

```cpp
#define MYSQL_PLUGIN_INTERFACE_VERSION 0x0105
```

Defined in plugin.h:84

MySQL plugin interface version

***

### MARIA\_PLUGIN\_INTERFACE\_VERSION

```cpp
#define MARIA_PLUGIN_INTERFACE_VERSION 0x0110
```

Defined in plugin.h:87

MariaDB plugin interface version

***

### MYSQL\_UDF\_PLUGIN

```cpp
#define MYSQL_UDF_PLUGIN 0
```

Defined in plugin.h:92

not implemented<br>

***

### MYSQL\_STORAGE\_ENGINE\_PLUGIN

```cpp
#define MYSQL_STORAGE_ENGINE_PLUGIN 1
```

Defined in plugin.h:93

***

### MYSQL\_FTPARSER\_PLUGIN

```cpp
#define MYSQL_FTPARSER_PLUGIN 2
```

Defined in plugin.h:94

Full-text parser plugin<br>

***

### MYSQL\_DAEMON\_PLUGIN

```cpp
#define MYSQL_DAEMON_PLUGIN 3
```

Defined in plugin.h:95

***

### MYSQL\_INFORMATION\_SCHEMA\_PLUGIN

```cpp
#define MYSQL_INFORMATION_SCHEMA_PLUGIN 4
```

Defined in plugin.h:96

***

### MYSQL\_AUDIT\_PLUGIN

```cpp
#define MYSQL_AUDIT_PLUGIN 5
```

Defined in plugin.h:97

***

### MYSQL\_REPLICATION\_PLUGIN

```cpp
#define MYSQL_REPLICATION_PLUGIN 6
```

Defined in plugin.h:98

***

### MYSQL\_AUTHENTICATION\_PLUGIN

```cpp
#define MYSQL_AUTHENTICATION_PLUGIN 7
```

Defined in plugin.h:99

***

### MYSQL\_MAX\_PLUGIN\_TYPE\_NUM

```cpp
#define MYSQL_MAX_PLUGIN_TYPE_NUM 12
```

Defined in plugin.h:100

The number of plugin types

***

### MariaDB\_PASSWORD\_VALIDATION\_PLUGIN

```cpp
#define MariaDB_PASSWORD_VALIDATION_PLUGIN 8
```

Defined in plugin.h:104

Client and server password validation Encryption and key management plugins

***

### MariaDB\_ENCRYPTION\_PLUGIN

```cpp
#define MariaDB_ENCRYPTION_PLUGIN 9
```

Defined in plugin.h:106

Plugins for SQL data storage types

***

### MariaDB\_DATA\_TYPE\_PLUGIN

```cpp
#define MariaDB_DATA_TYPE_PLUGIN 10
```

Defined in plugin.h:108

Plugins for new native SQL functions

***

### MariaDB\_FUNCTION\_PLUGIN

```cpp
#define MariaDB_FUNCTION_PLUGIN 11
```

Defined in plugin.h:110

***

### PLUGIN\_LICENSE\_PROPRIETARY

```cpp
#define PLUGIN_LICENSE_PROPRIETARY 0
```

Defined in plugin.h:113

***

### PLUGIN\_LICENSE\_GPL

```cpp
#define PLUGIN_LICENSE_GPL 1
```

Defined in plugin.h:114

***

### PLUGIN\_LICENSE\_BSD

```cpp
#define PLUGIN_LICENSE_BSD 2
```

Defined in plugin.h:115

***

### PLUGIN\_LICENSE\_PROPRIETARY\_STRING

```cpp
#define PLUGIN_LICENSE_PROPRIETARY_STRING "PROPRIETARY"
```

Defined in plugin.h:117

***

### PLUGIN\_LICENSE\_GPL\_STRING

```cpp
#define PLUGIN_LICENSE_GPL_STRING "GPL"
```

Defined in plugin.h:118

***

### PLUGIN\_LICENSE\_BSD\_STRING

```cpp
#define PLUGIN_LICENSE_BSD_STRING "BSD"
```

Defined in plugin.h:119

***

### MariaDB\_PLUGIN\_MATURITY\_UNKNOWN

```cpp
#define MariaDB_PLUGIN_MATURITY_UNKNOWN 0
```

Defined in plugin.h:122

***

### MariaDB\_PLUGIN\_MATURITY\_EXPERIMENTAL

```cpp
#define MariaDB_PLUGIN_MATURITY_EXPERIMENTAL 1
```

Defined in plugin.h:123

***

### MariaDB\_PLUGIN\_MATURITY\_ALPHA

```cpp
#define MariaDB_PLUGIN_MATURITY_ALPHA 2
```

Defined in plugin.h:124

***

### MariaDB\_PLUGIN\_MATURITY\_BETA

```cpp
#define MariaDB_PLUGIN_MATURITY_BETA 3
```

Defined in plugin.h:125

***

### MariaDB\_PLUGIN\_MATURITY\_GAMMA

```cpp
#define MariaDB_PLUGIN_MATURITY_GAMMA 4
```

Defined in plugin.h:126

***

### MariaDB\_PLUGIN\_MATURITY\_STABLE

```cpp
#define MariaDB_PLUGIN_MATURITY_STABLE 5
```

Defined in plugin.h:127

***

### \_\_MYSQL\_DECLARE\_PLUGIN

```cpp
#define __MYSQL_DECLARE_PLUGIN(NAME, VERSION, PSIZE, DECLS) int VERSION= MYSQL_PLUGIN_INTERFACE_VERSION;                                  \
int PSIZE= sizeof(struct st_mysql_plugin);                                    \
struct st_mysql_plugin DECLS[]= {
```

Defined in plugin.h:137

***

### MARIA\_DECLARE\_PLUGIN\_\_

```cpp
#define MARIA_DECLARE_PLUGIN__(NAME, VERSION, PSIZE, DECLS) MYSQL_PLUGIN_EXPORT int VERSION;                                              \
int VERSION= MARIA_PLUGIN_INTERFACE_VERSION;                                  \
MYSQL_PLUGIN_EXPORT int PSIZE;                                                \
int PSIZE= sizeof(struct st_maria_plugin);                                    \
MYSQL_PLUGIN_EXPORT struct st_maria_plugin DECLS[];                           \
struct st_maria_plugin DECLS[]= {
```

Defined in plugin.h:142

***

### mysql\_declare\_plugin

```cpp
#define mysql_declare_plugin(NAME) __MYSQL_DECLARE_PLUGIN(NAME, \
                 builtin_ ## NAME ## _plugin_interface_version, \
                 builtin_ ## NAME ## _sizeof_struct_st_plugin, \
                 builtin_ ## NAME ## _plugin)
```

Defined in plugin.h:169

***

### maria\_declare\_plugin

```cpp
#define maria_declare_plugin(NAME) MARIA_DECLARE_PLUGIN__(NAME, \
                 builtin_maria_ ## NAME ## _plugin_interface_version, \
                 builtin_maria_ ## NAME ## _sizeof_struct_st_plugin, \
                 builtin_maria_ ## NAME ## _plugin)
```

Defined in plugin.h:175

***

### mysql\_declare\_plugin\_end

```cpp
#define mysql_declare_plugin_end ,{0,0,0,0,0,0,0,0,0,0,0,0,0}}
```

Defined in plugin.h:181

***

### maria\_declare\_plugin\_end

```cpp
#define maria_declare_plugin_end ,{0,0,0,0,0,0,0,0,0,0,0,0,0}}
```

Defined in plugin.h:182

***

### SHOW\_INT

```cpp
#define SHOW_INT SHOW_UINT
```

Defined in plugin.h:197

***

### SHOW\_LONG

```cpp
#define SHOW_LONG SHOW_ULONG
```

Defined in plugin.h:198

***

### SHOW\_LONGLONG

```cpp
#define SHOW_LONGLONG SHOW_ULONGLONG
```

Defined in plugin.h:199

***

### SHOW\_VAR\_FUNC\_BUFF\_SIZE

```cpp
#define SHOW_VAR_FUNC_BUFF_SIZE (256 * sizeof(void*))
```

Defined in plugin.h:214

***

### PLUGIN\_OPT\_NO\_INSTALL

```cpp
#define PLUGIN_OPT_NO_INSTALL 1UL
```

Defined in plugin.h:234

Not dynamically loadable

***

### PLUGIN\_OPT\_NO\_UNINSTALL

```cpp
#define PLUGIN_OPT_NO_UNINSTALL 2UL
```

Defined in plugin.h:235

Not dynamically unloadable

***

### PLUGIN\_VAR\_BOOL

```cpp
#define PLUGIN_VAR_BOOL 0x0001
```

Defined in plugin.h:243

***

### PLUGIN\_VAR\_INT

```cpp
#define PLUGIN_VAR_INT 0x0002
```

Defined in plugin.h:244

***

### PLUGIN\_VAR\_LONG

```cpp
#define PLUGIN_VAR_LONG 0x0003
```

Defined in plugin.h:245

***

### PLUGIN\_VAR\_LONGLONG

```cpp
#define PLUGIN_VAR_LONGLONG 0x0004
```

Defined in plugin.h:246

***

### PLUGIN\_VAR\_STR

```cpp
#define PLUGIN_VAR_STR 0x0005
```

Defined in plugin.h:247

***

### PLUGIN\_VAR\_ENUM

```cpp
#define PLUGIN_VAR_ENUM 0x0006
```

Defined in plugin.h:248

***

### PLUGIN\_VAR\_SET

```cpp
#define PLUGIN_VAR_SET 0x0007
```

Defined in plugin.h:249

***

### PLUGIN\_VAR\_DOUBLE

```cpp
#define PLUGIN_VAR_DOUBLE 0x0008
```

Defined in plugin.h:250

***

### PLUGIN\_VAR\_UNSIGNED

```cpp
#define PLUGIN_VAR_UNSIGNED 0x0080
```

Defined in plugin.h:251

***

### PLUGIN\_VAR\_THDLOCAL

```cpp
#define PLUGIN_VAR_THDLOCAL 0x0100
```

Defined in plugin.h:252

Variable is per-connection

***

### PLUGIN\_VAR\_READONLY

```cpp
#define PLUGIN_VAR_READONLY 0x0200
```

Defined in plugin.h:253

Server variable is read only

***

### PLUGIN\_VAR\_NOSYSVAR

```cpp
#define PLUGIN_VAR_NOSYSVAR 0x0400
```

Defined in plugin.h:254

Not a server variable

***

### PLUGIN\_VAR\_NOCMDOPT

```cpp
#define PLUGIN_VAR_NOCMDOPT 0x0800
```

Defined in plugin.h:255

Not a command line option

***

### PLUGIN\_VAR\_NOCMDARG

```cpp
#define PLUGIN_VAR_NOCMDARG 0x1000
```

Defined in plugin.h:256

No argument for cmd line

***

### PLUGIN\_VAR\_RQCMDARG

```cpp
#define PLUGIN_VAR_RQCMDARG 0x0000
```

Defined in plugin.h:257

Argument required for cmd line

***

### PLUGIN\_VAR\_OPCMDARG

```cpp
#define PLUGIN_VAR_OPCMDARG 0x2000
```

Defined in plugin.h:258

Argument optional for cmd line

***

### PLUGIN\_VAR\_DEPRECATED

```cpp
#define PLUGIN_VAR_DEPRECATED 0x4000
```

Defined in plugin.h:259

Server variable is deprecated

***

### PLUGIN\_VAR\_MEMALLOC

```cpp
#define PLUGIN_VAR_MEMALLOC 0x8000
```

Defined in plugin.h:260

String needs memory allocated

***

### PLUGIN\_VAR\_MASK

```cpp
#define PLUGIN_VAR_MASK (PLUGIN_VAR_READONLY | PLUGIN_VAR_NOSYSVAR | \
         PLUGIN_VAR_NOCMDOPT | PLUGIN_VAR_NOCMDARG | \
         PLUGIN_VAR_OPCMDARG | PLUGIN_VAR_RQCMDARG | \
         PLUGIN_VAR_DEPRECATED | PLUGIN_VAR_MEMALLOC)
```

Defined in plugin.h:310

***

### MYSQL\_PLUGIN\_VAR\_HEADER

```cpp
#define MYSQL_PLUGIN_VAR_HEADER int flags;                    \
  const char *name;             \
  const char *comment;          \
  mysql_var_check_func check;   \
  mysql_var_update_func update
```

Defined in plugin.h:316

***

### MYSQL\_SYSVAR\_NAME

```cpp
#define MYSQL_SYSVAR_NAME(name) mysql_sysvar_ ## name
```

Defined in plugin.h:323

***

### MYSQL\_SYSVAR

```cpp
#define MYSQL_SYSVAR(name) ((struct st_mysql_sys_var *)&(MYSQL_SYSVAR_NAME(name)))
```

Defined in plugin.h:324

***

### DECLARE\_MYSQL\_SYSVAR\_BASIC

```cpp
#define DECLARE_MYSQL_SYSVAR_BASIC(name, type) struct { \
  MYSQL_PLUGIN_VAR_HEADER;      \
  type *value;                  \
  const type def_val;                 \
} MYSQL_SYSVAR_NAME(name)
```

Defined in plugin.h:335

***

### DECLARE\_MYSQL\_SYSVAR\_CONST\_BASIC

```cpp
#define DECLARE_MYSQL_SYSVAR_CONST_BASIC(name, type) struct { \
  MYSQL_PLUGIN_VAR_HEADER;      \
  const type *value;                  \
  const type def_val;                 \
} MYSQL_SYSVAR_NAME(name)
```

Defined in plugin.h:341

***

### DECLARE\_MYSQL\_SYSVAR\_SIMPLE

```cpp
#define DECLARE_MYSQL_SYSVAR_SIMPLE(name, type) struct { \
  MYSQL_PLUGIN_VAR_HEADER;      \
  type *value; type def_val;    \
  type min_val; type max_val;   \
  type blk_sz;                  \
} MYSQL_SYSVAR_NAME(name)
```

Defined in plugin.h:347

***

### DECLARE\_MYSQL\_SYSVAR\_TYPELIB

```cpp
#define DECLARE_MYSQL_SYSVAR_TYPELIB(name, type) struct { \
  MYSQL_PLUGIN_VAR_HEADER;      \
  type *value; type def_val;    \
  TYPELIB *typelib;             \
} MYSQL_SYSVAR_NAME(name)
```

Defined in plugin.h:354

***

### DECLARE\_THDVAR\_FUNC

```cpp
#define DECLARE_THDVAR_FUNC(type) type *(*resolve)(MYSQL_THD thd, int offset)
```

Defined in plugin.h:360

***

### DECLARE\_MYSQL\_THDVAR\_BASIC

```cpp
#define DECLARE_MYSQL_THDVAR_BASIC(name, type) struct { \
  MYSQL_PLUGIN_VAR_HEADER;      \
  int offset;                   \
  const type def_val;           \
  DECLARE_THDVAR_FUNC(type);    \
} MYSQL_SYSVAR_NAME(name)
```

Defined in plugin.h:363

***

### DECLARE\_MYSQL\_THDVAR\_SIMPLE

```cpp
#define DECLARE_MYSQL_THDVAR_SIMPLE(name, type) struct { \
  MYSQL_PLUGIN_VAR_HEADER;      \
  int offset;                   \
  type def_val; type min_val;   \
  type max_val; type blk_sz;    \
  DECLARE_THDVAR_FUNC(type);    \
} MYSQL_SYSVAR_NAME(name)
```

Defined in plugin.h:370

***

### DECLARE\_MYSQL\_THDVAR\_TYPELIB

```cpp
#define DECLARE_MYSQL_THDVAR_TYPELIB(name, type) struct { \
  MYSQL_PLUGIN_VAR_HEADER;      \
  int offset;                   \
  const type def_val;           \
  DECLARE_THDVAR_FUNC(type);    \
  TYPELIB *typelib;             \
} MYSQL_SYSVAR_NAME(name)
```

Defined in plugin.h:378

***

### MYSQL\_SYSVAR\_BOOL

```cpp
#define MYSQL_SYSVAR_BOOL(name, varname, opt, comment, check, update, def) DECLARE_MYSQL_SYSVAR_BASIC(name, char) = { \
  PLUGIN_VAR_BOOL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def}
```

Defined in plugin.h:391

***

### MYSQL\_SYSVAR\_STR

```cpp
#define MYSQL_SYSVAR_STR(name, varname, opt, comment, check, update, def) DECLARE_MYSQL_SYSVAR_BASIC(name, char *) = { \
  PLUGIN_VAR_STR | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def}
```

Defined in plugin.h:396

***

### MYSQL\_SYSVAR\_CONST\_STR

```cpp
#define MYSQL_SYSVAR_CONST_STR(name, varname, opt, comment, check, update, def) DECLARE_MYSQL_SYSVAR_CONST_BASIC(name, char *) = { \
  PLUGIN_VAR_STR | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def}
```

Defined in plugin.h:401

***

### MYSQL\_SYSVAR\_INT

```cpp
#define MYSQL_SYSVAR_INT(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, int) = { \
  PLUGIN_VAR_INT | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:406

***

### MYSQL\_SYSVAR\_UINT

```cpp
#define MYSQL_SYSVAR_UINT(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, unsigned int) = { \
  PLUGIN_VAR_INT | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:411

***

### MYSQL\_SYSVAR\_LONG

```cpp
#define MYSQL_SYSVAR_LONG(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, long) = { \
  PLUGIN_VAR_LONG | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:416

***

### MYSQL\_SYSVAR\_ULONG

```cpp
#define MYSQL_SYSVAR_ULONG(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, unsigned long) = { \
  PLUGIN_VAR_LONG | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:421

***

### MYSQL\_SYSVAR\_LONGLONG

```cpp
#define MYSQL_SYSVAR_LONGLONG(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, long long) = { \
  PLUGIN_VAR_LONGLONG | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:426

***

### MYSQL\_SYSVAR\_ULONGLONG

```cpp
#define MYSQL_SYSVAR_ULONGLONG(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, unsigned long long) = { \
  PLUGIN_VAR_LONGLONG | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:431

***

### MYSQL\_SYSVAR\_UINT64\_T

```cpp
#define MYSQL_SYSVAR_UINT64_T(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, uint64_t) = { \
  PLUGIN_VAR_LONGLONG | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:436

***

### MYSQL\_SYSVAR\_SIZE\_T

```cpp
#define MYSQL_SYSVAR_SIZE_T(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, size_t) = { \
  PLUGIN_VAR_LONG | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:447

***

### MYSQL\_SYSVAR\_ENUM

```cpp
#define MYSQL_SYSVAR_ENUM(name, varname, opt, comment, check, update, def, typelib) DECLARE_MYSQL_SYSVAR_TYPELIB(name, unsigned long) = { \
  PLUGIN_VAR_ENUM | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, typelib }
```

Defined in plugin.h:453

***

### MYSQL\_SYSVAR\_SET

```cpp
#define MYSQL_SYSVAR_SET(name, varname, opt, comment, check, update, def, typelib) DECLARE_MYSQL_SYSVAR_TYPELIB(name, unsigned long long) = { \
  PLUGIN_VAR_SET | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, typelib }
```

Defined in plugin.h:458

***

### MYSQL\_SYSVAR\_DOUBLE

```cpp
#define MYSQL_SYSVAR_DOUBLE(name, varname, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_SYSVAR_SIMPLE(name, double) = { \
  PLUGIN_VAR_DOUBLE | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, &varname, def, min, max, blk }
```

Defined in plugin.h:463

***

### MYSQL\_THDVAR\_BOOL

```cpp
#define MYSQL_THDVAR_BOOL(name, opt, comment, check, update, def) DECLARE_MYSQL_THDVAR_BASIC(name, char) = { \
  PLUGIN_VAR_BOOL | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, NULL}
```

Defined in plugin.h:468

***

### MYSQL\_THDVAR\_STR

```cpp
#define MYSQL_THDVAR_STR(name, opt, comment, check, update, def) DECLARE_MYSQL_THDVAR_BASIC(name, char *) = { \
  PLUGIN_VAR_STR | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, NULL}
```

Defined in plugin.h:473

***

### MYSQL\_THDVAR\_INT

```cpp
#define MYSQL_THDVAR_INT(name, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_THDVAR_SIMPLE(name, int) = { \
  PLUGIN_VAR_INT | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, min, max, blk, NULL }
```

Defined in plugin.h:478

***

### MYSQL\_THDVAR\_UINT

```cpp
#define MYSQL_THDVAR_UINT(name, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_THDVAR_SIMPLE(name, unsigned int) = { \
  PLUGIN_VAR_INT | PLUGIN_VAR_THDLOCAL | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, min, max, blk, NULL }
```

Defined in plugin.h:483

***

### MYSQL\_THDVAR\_LONG

```cpp
#define MYSQL_THDVAR_LONG(name, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_THDVAR_SIMPLE(name, long) = { \
  PLUGIN_VAR_LONG | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, min, max, blk, NULL }
```

Defined in plugin.h:488

***

### MYSQL\_THDVAR\_ULONG

```cpp
#define MYSQL_THDVAR_ULONG(name, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_THDVAR_SIMPLE(name, unsigned long) = { \
  PLUGIN_VAR_LONG | PLUGIN_VAR_THDLOCAL | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, min, max, blk, NULL }
```

Defined in plugin.h:493

***

### MYSQL\_THDVAR\_LONGLONG

```cpp
#define MYSQL_THDVAR_LONGLONG(name, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_THDVAR_SIMPLE(name, long long) = { \
  PLUGIN_VAR_LONGLONG | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, min, max, blk, NULL }
```

Defined in plugin.h:498

***

### MYSQL\_THDVAR\_ULONGLONG

```cpp
#define MYSQL_THDVAR_ULONGLONG(name, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_THDVAR_SIMPLE(name, unsigned long long) = { \
  PLUGIN_VAR_LONGLONG | PLUGIN_VAR_THDLOCAL | PLUGIN_VAR_UNSIGNED | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, min, max, blk, NULL }
```

Defined in plugin.h:503

***

### MYSQL\_THDVAR\_ENUM

```cpp
#define MYSQL_THDVAR_ENUM(name, opt, comment, check, update, def, typelib) DECLARE_MYSQL_THDVAR_TYPELIB(name, unsigned long) = { \
  PLUGIN_VAR_ENUM | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, NULL, typelib }
```

Defined in plugin.h:508

***

### MYSQL\_THDVAR\_SET

```cpp
#define MYSQL_THDVAR_SET(name, opt, comment, check, update, def, typelib) DECLARE_MYSQL_THDVAR_TYPELIB(name, unsigned long long) = { \
  PLUGIN_VAR_SET | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, NULL, typelib }
```

Defined in plugin.h:513

***

### MYSQL\_THDVAR\_DOUBLE

```cpp
#define MYSQL_THDVAR_DOUBLE(name, opt, comment, check, update, def, min, max, blk) DECLARE_MYSQL_THDVAR_SIMPLE(name, double) = { \
  PLUGIN_VAR_DOUBLE | PLUGIN_VAR_THDLOCAL | ((opt) & PLUGIN_VAR_MASK), \
  #name, comment, check, update, -1, def, min, max, blk, NULL }
```

Defined in plugin.h:518

***

### SYSVAR

```cpp
#define SYSVAR(name) (*(MYSQL_SYSVAR_NAME(name).value))
```

Defined in plugin.h:525

***

### THDVAR

```cpp
#define THDVAR(thd, name) (*(MYSQL_SYSVAR_NAME(name).resolve(thd, MYSQL_SYSVAR_NAME(name).offset)))
```

Defined in plugin.h:529

***

### MYSQL\_DAEMON\_INTERFACE\_VERSION

```cpp
#define MYSQL_DAEMON_INTERFACE_VERSION (MYSQL_VERSION_ID << 8)
```

Defined in plugin.h:600

***

### MYSQL\_INFORMATION\_SCHEMA\_INTERFACE\_VERSION

```cpp
#define MYSQL_INFORMATION_SCHEMA_INTERFACE_VERSION (MYSQL_VERSION_ID << 8)
```

Defined in plugin.h:618

***

### MYSQL\_HANDLERTON\_INTERFACE\_VERSION

```cpp
#define MYSQL_HANDLERTON_INTERFACE_VERSION (MYSQL_VERSION_ID << 8)
```

Defined in plugin.h:636

***

### MYSQL\_REPLICATION\_INTERFACE\_VERSION

```cpp
#define MYSQL_REPLICATION_INTERFACE_VERSION 0x0200
```

Defined in plugin.h:655

***

### MYSQL\_VALUE\_TYPE\_STRING

```cpp
#define MYSQL_VALUE_TYPE_STRING 0
```

Defined in plugin.h:664

***

### MYSQL\_VALUE\_TYPE\_REAL

```cpp
#define MYSQL_VALUE_TYPE_REAL 1
```

Defined in plugin.h:665

***

### MYSQL\_VALUE\_TYPE\_INT

```cpp
#define MYSQL_VALUE_TYPE_INT 2
```

Defined in plugin.h:666

***

### MYSQL\_SERVICES\_INCLUDED

```cpp
#define MYSQL_SERVICES_INCLUDED
```

Defined in services.h:51

***

### PSI\_PS\_CALL

```cpp
#define PSI_PS_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_ps.h:34

***

### MYSQL\_CREATE\_PS

```cpp
#define MYSQL_CREATE_PS(IDENTITY, ID, LOCKER, NAME, NAME_LENGTH) NULL
```

Defined in psi/mysql\_ps.h:49

***

### MYSQL\_EXECUTE\_PS

```cpp
#define MYSQL_EXECUTE_PS(LOCKER, PREPARED_STMT) do {} while (0)
```

Defined in psi/mysql\_ps.h:51

***

### MYSQL\_DESTROY\_PS

```cpp
#define MYSQL_DESTROY_PS(PREPARED_STMT) do {} while (0)
```

Defined in psi/mysql\_ps.h:53

***

### MYSQL\_REPREPARE\_PS

```cpp
#define MYSQL_REPREPARE_PS(PREPARED_STMT) do {} while (0)
```

Defined in psi/mysql\_ps.h:55

***

### MYSQL\_SET\_PS\_TEXT

```cpp
#define MYSQL_SET_PS_TEXT(PREPARED_STMT, SQLTEXT, SQLTEXT_LENGTH) do {} while (0)
```

Defined in psi/mysql\_ps.h:57

***

### PSI\_SP\_CALL

```cpp
#define PSI_SP_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_sp.h:34

***

### MYSQL\_START\_SP

```cpp
#define MYSQL_START_SP(STATE, SP_SHARE) NULL
```

Defined in psi/mysql\_sp.h:41

***

### MYSQL\_END\_SP

```cpp
#define MYSQL_END_SP(LOCKER) do {} while (0)
```

Defined in psi/mysql\_sp.h:50

***

### MYSQL\_DROP\_SP

```cpp
#define MYSQL_DROP_SP(OT, SN, SNL, ON, ONL) do {} while (0)
```

Defined in psi/mysql\_sp.h:58

***

### MYSQL\_GET\_SP\_SHARE

```cpp
#define MYSQL_GET_SP_SHARE(OT, SN, SNL, ON, ONL) NULL
```

Defined in psi/mysql\_sp.h:66

***

### PSI\_INSTRUMENT\_ME

```cpp
#define PSI_INSTRUMENT_ME 0
```

Defined in psi/psi\_base.h:47

***

### PSI\_INSTRUMENT\_MEM

```cpp
#define PSI_INSTRUMENT_MEM ((PSI_memory_key)0)
```

Defined in psi/psi\_base.h:48

***

### PSI\_NOT\_INSTRUMENTED

```cpp
#define PSI_NOT_INSTRUMENTED 0
```

Defined in psi/psi\_base.h:50

***

### PSI\_FLAG\_GLOBAL

```cpp
#define PSI_FLAG_GLOBAL (1 << 0)
```

Defined in psi/psi\_base.h:57

Global flag. This flag indicate that an instrumentation point is a global variable, or a singleton.

***

### PSI\_FLAG\_MUTABLE

```cpp
#define PSI_FLAG_MUTABLE (1 << 1)
```

Defined in psi/psi\_base.h:64

Mutable flag. This flag indicate that an instrumentation point is a general placeholder, that can mutate into a more specific instrumentation point.

***

### PSI\_FLAG\_THREAD

```cpp
#define PSI_FLAG_THREAD (1 << 2)
```

Defined in psi/psi\_base.h:66

***

### PSI\_FLAG\_STAGE\_PROGRESS

```cpp
#define PSI_FLAG_STAGE_PROGRESS (1 << 3)
```

Defined in psi/psi\_base.h:73

Stage progress flag. This flag apply to the stage instruments only. It indicates the instrumentation provides progress data.

***

### PSI\_RWLOCK\_FLAG\_SX

```cpp
#define PSI_RWLOCK_FLAG_SX (1 << 4)
```

Defined in psi/psi\_base.h:79

Shared Exclusive flag. Indicates that rwlock support the shared exclusive state.

***

### PSI\_FLAG\_TRANSFER

```cpp
#define PSI_FLAG_TRANSFER (1 << 5)
```

Defined in psi/psi\_base.h:86

Transferable flag. This flag indicate that an instrumented object can be created by a thread and destroyed by another thread.

***

### PSI\_FLAG\_VOLATILITY\_SESSION

```cpp
#define PSI_FLAG_VOLATILITY_SESSION (1 << 6)
```

Defined in psi/psi\_base.h:94

Volatility flag. This flag indicate that an instrumented object has a volatility (life cycle) comparable to the volatility of a session.

***

### PSI\_FLAG\_THREAD\_SYSTEM

```cpp
#define PSI_FLAG_THREAD_SYSTEM (1 << 9)
```

Defined in psi/psi\_base.h:100

System thread flag. Indicates that the instrumented object exists on a system thread.

***

### PSI\_CALL\_start\_metadata\_wait

```cpp
#define PSI_CALL_start_metadata_wait(A, B, C, D) 0
```

Defined in psi/mysql\_mdl.h:45

***

### PSI\_CALL\_end\_metadata\_wait

```cpp
#define PSI_CALL_end_metadata_wait(A, B) do { } while(0)
```

Defined in psi/mysql\_mdl.h:46

***

### PSI\_CALL\_create\_metadata\_lock

```cpp
#define PSI_CALL_create_metadata_lock(A, B, C, D, E, F, G) 0
```

Defined in psi/mysql\_mdl.h:47

***

### PSI\_CALL\_set\_metadata\_lock\_status

```cpp
#define PSI_CALL_set_metadata_lock_status(A, B) do {} while(0)
```

Defined in psi/mysql\_mdl.h:48

***

### PSI\_CALL\_destroy\_metadata\_lock

```cpp
#define PSI_CALL_destroy_metadata_lock(A) do {} while(0)
```

Defined in psi/mysql\_mdl.h:49

***

### mysql\_mdl\_create

```cpp
#define mysql_mdl_create(I, K, T, D, S, F, L, I, K, T, D, S, F, L) NULL
```

Defined in psi/mysql\_mdl.h:74

Instrumented metadata lock creation.

#### Parameters

| Parameter | Type | Description            |
| --------- | ---- | ---------------------- |
| `I`       |      | Metadata lock identity |
| `K`       |      | Metadata key           |
| `T`       |      | Metadata lock type     |
| `D`       |      | Metadata lock duration |
| `S`       |      | Metadata lock status   |
| `F`       |      | request source file    |
| `L`       |      | request source line    |
| `I`       |      | Metadata lock identity |
| `K`       |      | Metadata key           |
| `T`       |      | Metadata lock type     |
| `D`       |      | Metadata lock duration |
| `S`       |      | Metadata lock status   |
| `F`       |      | request source file    |
| `L`       |      | request source line    |

***

### mysql\_mdl\_set\_status

```cpp
#define mysql_mdl_set_status(L, S, L, S) do {} while (0)
```

Defined in psi/mysql\_mdl.h:81

***

### mysql\_mdl\_destroy

```cpp
#define mysql_mdl_destroy(M, M) do {} while (0)
```

Defined in psi/mysql\_mdl.h:95

Instrumented metadata lock destruction.

#### Parameters

| Parameter | Type | Description   |
| --------- | ---- | ------------- |
| `M`       |      | Metadata lock |
| `M`       |      | Metadata lock |

***

### PSI\_FILE\_CALL

```cpp
#define PSI_FILE_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_file.h:52

***

### mysql\_file\_register

```cpp
#define mysql_file_register(P1, P2, P3, P1, P2, P3) inline_mysql_file_register(P1, P2, P3)
```

Defined in psi/mysql\_file.h:65

File registration.

***

### mysql\_file\_fgets

```cpp
#define mysql_file_fgets(P1, P2, F, P1, P2, F) inline_mysql_file_fgets(P1, P2, F)
```

Defined in psi/mysql\_file.h:77

Instrumented fgets. `mysql_file_fgets` is a replacement for `fgets`.

***

### mysql\_file\_fgetc

```cpp
#define mysql_file_fgetc(F, F) inline_mysql_file_fgetc(F)
```

Defined in psi/mysql\_file.h:89

Instrumented fgetc. `mysql_file_fgetc` is a replacement for `fgetc`.

***

### mysql\_file\_fputs

```cpp
#define mysql_file_fputs(P1, F, P1, F) inline_mysql_file_fputs(P1, F)
```

Defined in psi/mysql\_file.h:101

Instrumented fputs. `mysql_file_fputs` is a replacement for `fputs`.

***

### mysql\_file\_fputc

```cpp
#define mysql_file_fputc(P1, F, P1, F) inline_mysql_file_fputc(P1, F)
```

Defined in psi/mysql\_file.h:114

Instrumented fputc. `mysql_file_fputc` is a replacement for `fputc`.

***

### mysql\_file\_fprintf

```cpp
#define mysql_file_fprintf inline_mysql_file_fprintf
```

Defined in psi/mysql\_file.h:123

Instrumented fprintf. `mysql_file_fprintf` is a replacement for `fprintf`.

***

### mysql\_file\_vfprintf

```cpp
#define mysql_file_vfprintf(F, P1, P2, F, P1, P2) inline_mysql_file_vfprintf(F, P1, P2)
```

Defined in psi/mysql\_file.h:134

Instrumented vfprintf. `mysql_file_vfprintf` is a replacement for `vfprintf`.

***

### mysql\_file\_fflush

```cpp
#define mysql_file_fflush(F, F) inline_mysql_file_fflush(F)
```

Defined in psi/mysql\_file.h:147

Instrumented fflush. `mysql_file_fflush` is a replacement for `fflush`.

***

### mysql\_file\_feof

```cpp
#define mysql_file_feof(F, F) inline_mysql_file_feof(F)
```

Defined in psi/mysql\_file.h:156

Instrumented feof. `mysql_file_feof` is a replacement for `feof`.

***

### mysql\_file\_fstat

```cpp
#define mysql_file_fstat(FN, S, FL, FN, S, FL) inline_mysql_file_fstat(FN, S, FL)
```

Defined in psi/mysql\_file.h:167

Instrumented fstat. `mysql_file_fstat` is a replacement for `my_fstat`.

***

### mysql\_file\_stat

```cpp
#define mysql_file_stat(K, FN, S, FL, K, FN, S, FL) inline_mysql_file_stat(FN, S, FL)
```

Defined in psi/mysql\_file.h:180

Instrumented stat. `mysql_file_stat` is a replacement for `my_stat`.

***

### mysql\_file\_chsize

```cpp
#define mysql_file_chsize(F, P1, P2, P3, F, P1, P2, P3) inline_mysql_file_chsize(F, P1, P2, P3)
```

Defined in psi/mysql\_file.h:193

Instrumented chsize. `mysql_file_chsize` is a replacement for `my_chsize`.

***

### mysql\_file\_fopen

```cpp
#define mysql_file_fopen(K, N, F1, F2, K, N, F1, F2) inline_mysql_file_fopen(N, F1, F2)
```

Defined in psi/mysql\_file.h:206

Instrumented fopen. `mysql_file_fopen` is a replacement for `my_fopen`.

***

### mysql\_file\_fclose

```cpp
#define mysql_file_fclose(FD, FL, FD, FL) inline_mysql_file_fclose(FD, FL)
```

Defined in psi/mysql\_file.h:226

Instrumented fclose. `mysql_file_fclose` is a replacement for `my_fclose`. Without the instrumentation, this call will have the same behavior as the undocumented and possibly platform specific my\_fclose(NULL, ...) behavior. With the instrumentation, mysql\_fclose(NULL, ...) will safely return 0, which is an extension compared to my\_fclose and is therefore compliant. mysql\_fclose is on purpose *not* implementing

```cpp
assert(file != NULL) 
```

, since doing so could introduce regressions.

***

### mysql\_file\_fread

```cpp
#define mysql_file_fread(FD, P1, P2, P3, FD, P1, P2, P3) inline_mysql_file_fread(FD, P1, P2, P3)
```

Defined in psi/mysql\_file.h:239

Instrumented fread. `mysql_file_fread` is a replacement for `my_fread`.

***

### mysql\_file\_fwrite

```cpp
#define mysql_file_fwrite(FD, P1, P2, P3, FD, P1, P2, P3) inline_mysql_file_fwrite(FD, P1, P2, P3)
```

Defined in psi/mysql\_file.h:252

Instrumented fwrite. `mysql_file_fwrite` is a replacement for `my_fwrite`.

***

### mysql\_file\_fseek

```cpp
#define mysql_file_fseek(FD, P, W, F, FD, P, W, F) inline_mysql_file_fseek(FD, P, W, F)
```

Defined in psi/mysql\_file.h:265

Instrumented fseek. `mysql_file_fseek` is a replacement for `my_fseek`.

***

### mysql\_file\_ftell

```cpp
#define mysql_file_ftell(FD, F, FD, F) inline_mysql_file_ftell(FD, F)
```

Defined in psi/mysql\_file.h:278

Instrumented ftell. `mysql_file_ftell` is a replacement for `my_ftell`.

***

### mysql\_file\_create

```cpp
#define mysql_file_create(K, N, F1, F2, F3, K, N, F1, F2, F3) inline_mysql_file_create(N, F1, F2, F3)
```

Defined in psi/mysql\_file.h:291

Instrumented create. `mysql_file_create` is a replacement for `my_create`.

***

### mysql\_file\_create\_temp

```cpp
#define mysql_file_create_temp(K, T, D, P, M, F, K, T, D, P, M, F) inline_mysql_file_create_temp(T, D, P, M, F)
```

Defined in psi/mysql\_file.h:304

Instrumented create\_temp\_file. `mysql_file_create_temp` is a replacement for `create_temp_file`.

***

### mysql\_file\_open

```cpp
#define mysql_file_open(K, N, F1, F2, K, N, F1, F2) inline_mysql_file_open(N, F1, F2)
```

Defined in psi/mysql\_file.h:317

Instrumented open. `mysql_file_open` is a replacement for `my_open`.

***

### mysql\_file\_close

```cpp
#define mysql_file_close(FD, F, FD, F) inline_mysql_file_close(FD, F)
```

Defined in psi/mysql\_file.h:330

Instrumented close. `mysql_file_close` is a replacement for `my_close`.

***

### mysql\_file\_read

```cpp
#define mysql_file_read(FD, B, S, F, FD, B, S, F) inline_mysql_file_read(FD, B, S, F)
```

Defined in psi/mysql\_file.h:343

Instrumented read. `mysql_read` is a replacement for `my_read`.

***

### mysql\_file\_write

```cpp
#define mysql_file_write(FD, B, S, F, FD, B, S, F) inline_mysql_file_write(FD, B, S, F)
```

Defined in psi/mysql\_file.h:356

Instrumented write. `mysql_file_write` is a replacement for `my_write`.

***

### mysql\_file\_pread

```cpp
#define mysql_file_pread(FD, B, S, O, F, FD, B, S, O, F) inline_mysql_file_pread(FD, B, S, O, F)
```

Defined in psi/mysql\_file.h:369

Instrumented pread. `mysql_pread` is a replacement for `my_pread`.

***

### mysql\_file\_pwrite

```cpp
#define mysql_file_pwrite(FD, B, S, O, F, FD, B, S, O, F) inline_mysql_file_pwrite(FD, B, S, O, F)
```

Defined in psi/mysql\_file.h:382

Instrumented pwrite. `mysql_file_pwrite` is a replacement for `my_pwrite`.

***

### mysql\_file\_seek

```cpp
#define mysql_file_seek(FD, P, W, F, FD, P, W, F) inline_mysql_file_seek(FD, P, W, F)
```

Defined in psi/mysql\_file.h:395

Instrumented seek. `mysql_file_seek` is a replacement for `my_seek`.

***

### mysql\_file\_tell

```cpp
#define mysql_file_tell(FD, F, FD, F) inline_mysql_file_tell(FD, F)
```

Defined in psi/mysql\_file.h:408

Instrumented tell. `mysql_file_tell` is a replacement for `my_tell`.

***

### mysql\_file\_delete

```cpp
#define mysql_file_delete(K, P1, P2, K, P1, P2) inline_mysql_file_delete(P1, P2)
```

Defined in psi/mysql\_file.h:421

Instrumented delete. `mysql_file_delete` is a replacement for `my_delete`.

***

### mysql\_file\_rename

```cpp
#define mysql_file_rename(K, P1, P2, P3, K, P1, P2, P3) inline_mysql_file_rename(P1, P2, P3)
```

Defined in psi/mysql\_file.h:434

Instrumented rename. `mysql_file_rename` is a replacement for `my_rename`.

***

### mysql\_file\_create\_with\_symlink

```cpp
#define mysql_file_create_with_symlink(K, P1, P2, P3, P4, P5, K, P1, P2, P3, P4, P5) inline_mysql_file_create_with_symlink(P1, P2, P3, P4, P5)
```

Defined in psi/mysql\_file.h:449

Instrumented create with symbolic link. `mysql_file_create_with_symlink` is a replacement for `my_create_with_symlink`.

***

### mysql\_file\_delete\_with\_symlink

```cpp
#define mysql_file_delete_with_symlink(K, P1, P2, P3, K, P1, P2, P3) inline_mysql_file_delete_with_symlink(P1, P2, P3)
```

Defined in psi/mysql\_file.h:463

Instrumented delete with symbolic link. `mysql_file_delete_with_symlink` is a replacement for `my_handler_delete_with_symlink`.

***

### mysql\_file\_rename\_with\_symlink

```cpp
#define mysql_file_rename_with_symlink(K, P1, P2, P3, K, P1, P2, P3) inline_mysql_file_rename_with_symlink(P1, P2, P3)
```

Defined in psi/mysql\_file.h:477

Instrumented rename with symbolic link. `mysql_file_rename_with_symlink` is a replacement for `my_rename_with_symlink`.

***

### mysql\_file\_sync

```cpp
#define mysql_file_sync(P1, P2, P1, P2) inline_mysql_file_sync(P1, P2)
```

Defined in psi/mysql\_file.h:490

Instrumented file sync. `mysql_file_sync` is a replacement for `my_sync`.

***

### PSI\_IDLE\_CALL

```cpp
#define PSI_IDLE_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_idle.h:35

***

### MYSQL\_START\_IDLE\_WAIT

```cpp
#define MYSQL_START_IDLE_WAIT(LOCKER, STATE, LOCKER, STATE) do {} while (0)
```

Defined in psi/mysql\_idle.h:56

Instrumentation helper for table io\_waits. This instrumentation marks the start of a wait event. **See also**: [MYSQL\_END\_IDLE\_WAIT](#mysql_end_idle_wait).

#### Parameters

| Parameter | Type | Description      |
| --------- | ---- | ---------------- |
| `LOCKER`  |      | the locker       |
| `STATE`   |      | the locker state |
| `LOCKER`  |      | the locker       |
| `STATE`   |      | the locker state |

***

### MYSQL\_END\_IDLE\_WAIT

```cpp
#define MYSQL_END_IDLE_WAIT(LOCKER, LOCKER) do {} while (0)
```

Defined in psi/mysql\_idle.h:71

Instrumentation helper for idle waits. This instrumentation marks the end of a wait event. **See also**: [MYSQL\_START\_IDLE\_WAIT](#mysql_start_idle_wait).

#### Parameters

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `LOCKER`  |      | the locker  |
| `LOCKER`  |      | the locker  |

***

### MYSQL\_PLUGIN\_AUTH\_INCLUDED

```cpp
#define MYSQL_PLUGIN_AUTH_INCLUDED
```

Defined in plugin\_auth.h:26

***

### MYSQL\_AUTHENTICATION\_INTERFACE\_VERSION

```cpp
#define MYSQL_AUTHENTICATION_INTERFACE_VERSION 0x0203
```

Defined in plugin\_auth.h:30

***

### PASSWORD\_USED\_NO

```cpp
#define PASSWORD_USED_NO 0
```

Defined in plugin\_auth.h:40

***

### PASSWORD\_USED\_YES

```cpp
#define PASSWORD_USED_YES 1
```

Defined in plugin\_auth.h:41

***

### PASSWORD\_USED\_NO\_MENTION

```cpp
#define PASSWORD_USED_NO_MENTION 2
```

Defined in plugin\_auth.h:42

***

### PSI\_STAGE\_CALL

```cpp
#define PSI_STAGE_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_stage.h:34

***

### mysql\_stage\_register

```cpp
#define mysql_stage_register(P1, P2, P3, P1, P2, P3) do {} while (0)
```

Defined in psi/mysql\_stage.h:51

Stage registration.

***

### MYSQL\_SET\_STAGE

```cpp
#define MYSQL_SET_STAGE(K, F, L, K, F, L) NULL
```

Defined in psi/mysql\_stage.h:69

Set the current stage. Use this API when the file and line is passed from the caller.

#### Returns

the current stage progress

#### Parameters

| Parameter | Type | Description          |
| --------- | ---- | -------------------- |
| `K`       |      | the stage key        |
| `F`       |      | the source file name |
| `L`       |      | the source file line |
| `K`       |      | the stage key        |
| `F`       |      | the source file name |
| `L`       |      | the source file line |

***

### mysql\_set\_stage

```cpp
#define mysql_set_stage(K, K) NULL
```

Defined in psi/mysql\_stage.h:83

Set the current stage.

#### Returns

the current stage progress

#### Parameters

| Parameter | Type | Description   |
| --------- | ---- | ------------- |
| `K`       |      | the stage key |
| `K`       |      | the stage key |

***

### mysql\_end\_stage

```cpp
#define mysql_end_stage() do {} while (0)
```

Defined in psi/mysql\_stage.h:95

End the last stage

***

### mysql\_stage\_set\_work\_completed

```cpp
#define mysql_stage_set_work_completed(P1, P2, P1, P2) do {} while (0)
```

Defined in psi/mysql\_stage.h:131

***

### mysql\_stage\_get\_work\_completed

```cpp
#define mysql_stage_get_work_completed(P1, P1) do {} while (0)
```

Defined in psi/mysql\_stage.h:134

***

### mysql\_stage\_inc\_work\_completed

```cpp
#define mysql_stage_inc_work_completed(P1, P2, P1, P2) do {} while (0)
```

Defined in psi/mysql\_stage.h:142

***

### mysql\_stage\_set\_work\_estimated

```cpp
#define mysql_stage_set_work_estimated(P1, P2, P1, P2) do {} while (0)
```

Defined in psi/mysql\_stage.h:153

***

### mysql\_stage\_get\_work\_estimated

```cpp
#define mysql_stage_get_work_estimated(P1, P1) do {} while (0)
```

Defined in psi/mysql\_stage.h:156

***

### PSI\_TABLE\_CALL

```cpp
#define PSI_TABLE_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_table.h:35

***

### MYSQL\_UNBIND\_TABLE

```cpp
#define MYSQL_UNBIND_TABLE(handler, handler) do { } while(0)
```

Defined in psi/mysql\_table.h:55

***

### PSI\_CALL\_unbind\_table

```cpp
#define PSI_CALL_unbind_table(A1, A1) do { } while(0)
```

Defined in psi/mysql\_table.h:57

***

### PSI\_CALL\_rebind\_table

```cpp
#define PSI_CALL_rebind_table(A1, A2, A3, A1, A2, A3) NULL
```

Defined in psi/mysql\_table.h:58

***

### PSI\_CALL\_close\_table

```cpp
#define PSI_CALL_close_table(A1, A2, A1, A2) do { } while(0)
```

Defined in psi/mysql\_table.h:59

***

### PSI\_CALL\_open\_table

```cpp
#define PSI_CALL_open_table(A1, A2, A1, A2) NULL
```

Defined in psi/mysql\_table.h:60

***

### PSI\_CALL\_get\_table\_share

```cpp
#define PSI_CALL_get_table_share(A1, A2, A1, A2) NULL
```

Defined in psi/mysql\_table.h:61

***

### PSI\_CALL\_release\_table\_share

```cpp
#define PSI_CALL_release_table_share(A1, A1) do { } while(0)
```

Defined in psi/mysql\_table.h:62

***

### PSI\_CALL\_drop\_table\_share

```cpp
#define PSI_CALL_drop_table_share(A1, A2, A3, A4, A5, A1, A2, A3, A4, A5) do { } while(0)
```

Defined in psi/mysql\_table.h:63

***

### MYSQL\_TABLE\_WAIT\_VARIABLES

```cpp
#define MYSQL_TABLE_WAIT_VARIABLES(LOCKER, STATE, LOCKER, STATE)
```

Defined in psi/mysql\_table.h:83

Instrumentation helper for table waits. This instrumentation declares local variables. Do not use a ';' after this macro **See also**: MYSQL\_START\_TABLE\_IO\_WAIT.

**See also**: MYSQL\_END\_TABLE\_IO\_WAIT.

**See also**: [MYSQL\_START\_TABLE\_LOCK\_WAIT](#mysql_start_table_lock_wait).

**See also**: [MYSQL\_END\_TABLE\_LOCK\_WAIT](#mysql_end_table_lock_wait).

#### Parameters

| Parameter | Type | Description      |
| --------- | ---- | ---------------- |
| `LOCKER`  |      | the locker       |
| `STATE`   |      | the locker state |
| `LOCKER`  |      | the locker       |
| `STATE`   |      | the locker state |

***

### MYSQL\_START\_TABLE\_LOCK\_WAIT

```cpp
#define MYSQL_START_TABLE_LOCK_WAIT(LOCKER, STATE, PSI, OP, FLAGS, LOCKER, STATE, PSI, OP, FLAGS) do {} while (0)
```

Defined in psi/mysql\_table.h:102

Instrumentation helper for table lock waits. This instrumentation marks the start of a wait event. **See also**: [MYSQL\_END\_TABLE\_LOCK\_WAIT](#mysql_end_table_lock_wait).

#### Parameters

| Parameter | Type | Description                         |
| --------- | ---- | ----------------------------------- |
| `LOCKER`  |      | the locker                          |
| `STATE`   |      | the locker state                    |
| `PSI`     |      | the instrumented table              |
| `OP`      |      | the table operation to be performed |
| `FLAGS`   |      | per table operation flags.          |
| `LOCKER`  |      | the locker                          |
| `STATE`   |      | the locker state                    |
| `PSI`     |      | the instrumented table              |
| `OP`      |      | the table operation to be performed |
| `FLAGS`   |      | per table operation flags.          |

***

### MYSQL\_END\_TABLE\_LOCK\_WAIT

```cpp
#define MYSQL_END_TABLE_LOCK_WAIT(LOCKER, LOCKER) do {} while (0)
```

Defined in psi/mysql\_table.h:117

Instrumentation helper for table lock waits. This instrumentation marks the end of a wait event. **See also**: [MYSQL\_START\_TABLE\_LOCK\_WAIT](#mysql_start_table_lock_wait).

#### Parameters

| Parameter | Type | Description |
| --------- | ---- | ----------- |
| `LOCKER`  |      | the locker  |
| `LOCKER`  |      | the locker  |

***

### MYSQL\_UNLOCK\_TABLE

```cpp
#define MYSQL_UNLOCK_TABLE(T, T) do {} while (0)
```

Defined in psi/mysql\_table.h:125

***

### MY\_GLOBAL\_INCLUDED

```cpp
#define MY_GLOBAL_INCLUDED
```

Defined in psi/psi\_abi\_v0.h:29

***

### USE\_PSI\_1

```cpp
#define USE_PSI_1
```

Defined in psi/psi\_abi\_v1.h:29

***

### HAVE\_PSI\_INTERFACE

```cpp
#define HAVE_PSI_INTERFACE
```

Defined in psi/psi\_abi\_v1.h:30

***

### MY\_GLOBAL\_INCLUDED

```cpp
#define MY_GLOBAL_INCLUDED
```

Defined in psi/psi\_abi\_v1.h:31

***

### USE\_PSI\_2

```cpp
#define USE_PSI_2
```

Defined in psi/psi\_abi\_v2.h:29

***

### HAVE\_PSI\_INTERFACE

```cpp
#define HAVE_PSI_INTERFACE
```

Defined in psi/psi\_abi\_v2.h:30

***

### MY\_GLOBAL\_INCLUDED

```cpp
#define MY_GLOBAL_INCLUDED
```

Defined in psi/psi\_abi\_v2.h:31

***

### MY\_MD5\_HASH\_SIZE

```cpp
#define MY_MD5_HASH_SIZE 16 /* Hash size in bytes */
```

Defined in service\_md5.h:32

***

### MYSQL\_SERVICE\_MD5\_INCLUDED

```cpp
#define MYSQL_SERVICE_MD5_INCLUDED
```

Defined in service\_md5.h:67

***

### MYSQL\_SERVICE\_THD\_INCLUDED

```cpp
#define MYSQL_SERVICE_THD_INCLUDED
```

Defined in service\_thd.h:45

***

### MYSQL\_AUDIT\_CLASS\_MASK\_SIZE

```cpp
#define MYSQL_AUDIT_CLASS_MASK_SIZE 1
```

Defined in plugin\_audit.h:30

***

### MYSQL\_AUDIT\_INTERFACE\_VERSION

```cpp
#define MYSQL_AUDIT_INTERFACE_VERSION 0x0304
```

Defined in plugin\_audit.h:32

***

### MYSQL\_AUDIT\_GENERAL\_CLASS

```cpp
#define MYSQL_AUDIT_GENERAL_CLASS 0
```

Defined in plugin\_audit.h:45

***

### MYSQL\_AUDIT\_GENERAL\_CLASSMASK

```cpp
#define MYSQL_AUDIT_GENERAL_CLASSMASK (1 << MYSQL_AUDIT_GENERAL_CLASS)
```

Defined in plugin\_audit.h:46

***

### MYSQL\_AUDIT\_GENERAL\_LOG

```cpp
#define MYSQL_AUDIT_GENERAL_LOG 0
```

Defined in plugin\_audit.h:47

***

### MYSQL\_AUDIT\_GENERAL\_ERROR

```cpp
#define MYSQL_AUDIT_GENERAL_ERROR 1
```

Defined in plugin\_audit.h:48

***

### MYSQL\_AUDIT\_GENERAL\_RESULT

```cpp
#define MYSQL_AUDIT_GENERAL_RESULT 2
```

Defined in plugin\_audit.h:49

***

### MYSQL\_AUDIT\_GENERAL\_STATUS

```cpp
#define MYSQL_AUDIT_GENERAL_STATUS 3
```

Defined in plugin\_audit.h:50

***

### MYSQL\_AUDIT\_GENERAL\_WARNING

```cpp
#define MYSQL_AUDIT_GENERAL_WARNING 4
```

Defined in plugin\_audit.h:51

***

### MYSQL\_AUDIT\_CONNECTION\_CLASS

```cpp
#define MYSQL_AUDIT_CONNECTION_CLASS 1
```

Defined in plugin\_audit.h:91

***

### MYSQL\_AUDIT\_CONNECTION\_CLASSMASK

```cpp
#define MYSQL_AUDIT_CONNECTION_CLASSMASK (1 << MYSQL_AUDIT_CONNECTION_CLASS)
```

Defined in plugin\_audit.h:92

***

### MYSQL\_AUDIT\_CONNECTION\_CONNECT

```cpp
#define MYSQL_AUDIT_CONNECTION_CONNECT 0
```

Defined in plugin\_audit.h:93

***

### MYSQL\_AUDIT\_CONNECTION\_DISCONNECT

```cpp
#define MYSQL_AUDIT_CONNECTION_DISCONNECT 1
```

Defined in plugin\_audit.h:94

***

### MYSQL\_AUDIT\_CONNECTION\_CHANGE\_USER

```cpp
#define MYSQL_AUDIT_CONNECTION_CHANGE_USER 2
```

Defined in plugin\_audit.h:95

***

### MYSQL\_AUDIT\_TABLE\_CLASS

```cpp
#define MYSQL_AUDIT_TABLE_CLASS 15
```

Defined in plugin\_audit.h:134

***

### MYSQL\_AUDIT\_TABLE\_CLASSMASK

```cpp
#define MYSQL_AUDIT_TABLE_CLASSMASK (1 << MYSQL_AUDIT_TABLE_CLASS)
```

Defined in plugin\_audit.h:135

***

### MYSQL\_AUDIT\_TABLE\_LOCK

```cpp
#define MYSQL_AUDIT_TABLE_LOCK 0
```

Defined in plugin\_audit.h:136

***

### MYSQL\_AUDIT\_TABLE\_CREATE

```cpp
#define MYSQL_AUDIT_TABLE_CREATE 1
```

Defined in plugin\_audit.h:137

***

### MYSQL\_AUDIT\_TABLE\_DROP

```cpp
#define MYSQL_AUDIT_TABLE_DROP 2
```

Defined in plugin\_audit.h:138

***

### MYSQL\_AUDIT\_TABLE\_RENAME

```cpp
#define MYSQL_AUDIT_TABLE_RENAME 3
```

Defined in plugin\_audit.h:139

***

### MYSQL\_AUDIT\_TABLE\_ALTER

```cpp
#define MYSQL_AUDIT_TABLE_ALTER 4
```

Defined in plugin\_audit.h:140

***

### PSI\_CALL\_memory\_alloc

```cpp
#define PSI_CALL_memory_alloc(A1, A2, A3) 0
```

Defined in psi/mysql\_memory.h:39

***

### PSI\_CALL\_memory\_free

```cpp
#define PSI_CALL_memory_free(A1, A2, A3) do { } while(0)
```

Defined in psi/mysql\_memory.h:40

***

### PSI\_CALL\_memory\_realloc

```cpp
#define PSI_CALL_memory_realloc(A1, A2, A3, A4) 0
```

Defined in psi/mysql\_memory.h:41

***

### PSI\_CALL\_register\_memory

```cpp
#define PSI_CALL_register_memory(A1, A2, A3) do { } while(0)
```

Defined in psi/mysql\_memory.h:42

***

### PSI\_MEMORY\_CALL

```cpp
#define PSI_MEMORY_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_memory.h:46

***

### mysql\_memory\_register

```cpp
#define mysql_memory_register(P1, P2, P3, P1, P2, P3) inline_mysql_memory_register(P1, P2, P3)
```

Defined in psi/mysql\_memory.h:59

Memory registration.

***

### SOCKBUF\_T

```cpp
#define SOCKBUF_T void
```

Defined in psi/mysql\_socket.h:41

***

### PSI\_SOCKET\_CALL

```cpp
#define PSI_SOCKET_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_socket.h:51

***

### mysql\_socket\_register

```cpp
#define mysql_socket_register(P1, P2, P3, P1, P2, P3) inline_mysql_socket_register(P1, P2, P3)
```

Defined in psi/mysql\_socket.h:65

Socket registration.

***

### MYSQL\_INVALID\_SOCKET

```cpp
#define MYSQL_INVALID_SOCKET mysql_socket_invalid()
```

Defined in psi/mysql\_socket.h:107

MYSQL\_SOCKET initial value.

***

### MYSQL\_SOCKET\_WAIT\_VARIABLES

```cpp
#define MYSQL_SOCKET_WAIT_VARIABLES(LOCKER, STATE, LOCKER, STATE) struct PSI_socket_locker* LOCKER; \
    PSI_socket_locker_state STATE;
```

Defined in psi/mysql\_socket.h:202

Instrumentation helper for socket waits. This instrumentation declares local variables. Do not use a ';' after this macro **See also**: [MYSQL\_START\_SOCKET\_WAIT](#mysql_start_socket_wait).

**See also**: [MYSQL\_END\_SOCKET\_WAIT](#mysql_end_socket_wait).

#### Parameters

| Parameter | Type | Description  |
| --------- | ---- | ------------ |
| `LOCKER`  |      | locker       |
| `STATE`   |      | locker state |
| `LOCKER`  |      | locker       |
| `STATE`   |      | locker state |

***

### MYSQL\_START\_SOCKET\_WAIT

```cpp
#define MYSQL_START_SOCKET_WAIT(LOCKER, STATE, SOCKET, OP, COUNT, LOCKER, STATE, SOCKET, OP, COUNT) LOCKER= inline_mysql_start_socket_wait(STATE, SOCKET, OP, COUNT,\
                                           __FILE__, __LINE__)
```

Defined in psi/mysql\_socket.h:221

Instrumentation helper for socket waits. This instrumentation marks the start of a wait event. **See also**: [MYSQL\_END\_SOCKET\_WAIT](#mysql_end_socket_wait).

#### Parameters

| Parameter | Type | Description                          |
| --------- | ---- | ------------------------------------ |
| `LOCKER`  |      | locker                               |
| `STATE`   |      | locker state                         |
| `SOCKET`  |      | instrumented socket                  |
| `OP`      |      | The socket operation to be performed |
| `COUNT`   |      | bytes to be written/read             |
| `LOCKER`  |      | locker                               |
| `STATE`   |      | locker state                         |
| `SOCKET`  |      | instrumented socket                  |
| `OP`      |      | The socket operation to be performed |
| `COUNT`   |      | bytes to be written/read             |

***

### MYSQL\_END\_SOCKET\_WAIT

```cpp
#define MYSQL_END_SOCKET_WAIT(LOCKER, COUNT, LOCKER, COUNT) inline_mysql_end_socket_wait(LOCKER, COUNT)
```

Defined in psi/mysql\_socket.h:238

Instrumentation helper for socket waits. This instrumentation marks the end of a wait event. **See also**: [MYSQL\_START\_SOCKET\_WAIT](#mysql_start_socket_wait).

#### Parameters

| Parameter | Type | Description                      |
| --------- | ---- | -------------------------------- |
| `LOCKER`  |      | locker                           |
| `COUNT`   |      | actual bytes written/read, or -1 |
| `LOCKER`  |      | locker                           |
| `COUNT`   |      | actual bytes written/read, or -1 |

***

### MYSQL\_SOCKET\_SET\_STATE

```cpp
#define MYSQL_SOCKET_SET_STATE(SOCKET, STATE, SOCKET, STATE) inline_mysql_socket_set_state(SOCKET, STATE)
```

Defined in psi/mysql\_socket.h:253

Set the state (IDLE, ACTIVE) of an instrumented socket. **See also**: PSI\_socket\_state

#### Parameters

| Parameter | Type | Description             |
| --------- | ---- | ----------------------- |
| `SOCKET`  |      | the instrumented socket |
| `STATE`   |      | the new state           |
| `SOCKET`  |      | the instrumented socket |
| `STATE`   |      | the new state           |

***

### mysql\_socket\_fd

```cpp
#define mysql_socket_fd(K, F, K, F) inline_mysql_socket_fd(K, F)
```

Defined in psi/mysql\_socket.h:317

Create a socket. `mysql_socket_fd` is a replacement for `socket`.

#### Parameters

| Parameter | Type | Description                                   |
| --------- | ---- | --------------------------------------------- |
| `K`       |      | PSI\_socket\_key for this instrumented socket |
| `F`       |      | File descriptor                               |
| `K`       |      | PSI\_socket\_key for this instrumented socket |
| `F`       |      | File descriptor                               |

***

### mysql\_socket\_socket

```cpp
#define mysql_socket_socket(K, D, T, P, K, D, T, P) inline_mysql_socket_socket(K, D, T, P)
```

Defined in psi/mysql\_socket.h:335

Create a socket. `mysql_socket_socket` is a replacement for `socket`.

#### Parameters

| Parameter | Type | Description                                   |
| --------- | ---- | --------------------------------------------- |
| `K`       |      | PSI\_socket\_key for this instrumented socket |
| `D`       |      | Socket domain                                 |
| `T`       |      | Protocol type                                 |
| `P`       |      | Transport protocol                            |
| `K`       |      | PSI\_socket\_key for this instrumented socket |
| `D`       |      | Socket domain                                 |
| `T`       |      | Protocol type                                 |
| `P`       |      | Transport protocol                            |

***

### mysql\_socket\_bind

```cpp
#define mysql_socket_bind(FD, AP, L, FD, AP, L) inline_mysql_socket_bind(__FILE__, __LINE__, FD, AP, L)
```

Defined in psi/mysql\_socket.h:351

Bind a socket to a local port number and IP address `mysql_socket_bind` is a replacement for `bind`.

#### Parameters

| Parameter | Type | Description                                                       |
| --------- | ---- | ----------------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket()               |
| `AP`      |      | Pointer to local port number and IP address in sockaddr structure |
| `L`       |      | Length of sockaddr structure                                      |
| `FD`      |      | Instrumented socket descriptor returned by socket()               |
| `AP`      |      | Pointer to local port number and IP address in sockaddr structure |
| `L`       |      | Length of sockaddr structure                                      |

***

### mysql\_socket\_getsockname

```cpp
#define mysql_socket_getsockname(FD, AP, LP, FD, AP, LP) inline_mysql_socket_getsockname(__FILE__, __LINE__, FD, AP, LP)
```

Defined in psi/mysql\_socket.h:367

Return port number and IP address of the local host `mysql_socket_getsockname` is a replacement for `getsockname`.

#### Parameters

| Parameter | Type | Description                                                       |
| --------- | ---- | ----------------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket()               |
| `AP`      |      | Pointer to returned address of local host in `sockaddr` structure |
| `LP`      |      | Pointer to length of `sockaddr` structure                         |
| `FD`      |      | Instrumented socket descriptor returned by socket()               |
| `AP`      |      | Pointer to returned address of local host in `sockaddr` structure |
| `LP`      |      | Pointer to length of `sockaddr` structure                         |

***

### mysql\_socket\_connect

```cpp
#define mysql_socket_connect(FD, AP, L, FD, AP, L) inline_mysql_socket_connect(__FILE__, __LINE__, FD, AP, L)
```

Defined in psi/mysql\_socket.h:383

Establish a connection to a remote host. `mysql_socket_connect` is a replacement for `connect`.

#### Parameters

| Parameter | Type | Description                                         |
| --------- | ---- | --------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket() |
| `AP`      |      | Pointer to target address in sockaddr structure     |
| `L`       |      | Length of sockaddr structure                        |
| `FD`      |      | Instrumented socket descriptor returned by socket() |
| `AP`      |      | Pointer to target address in sockaddr structure     |
| `L`       |      | Length of sockaddr structure                        |

***

### mysql\_socket\_getpeername

```cpp
#define mysql_socket_getpeername(FD, AP, LP, FD, AP, LP) inline_mysql_socket_getpeername(__FILE__, __LINE__, FD, AP, LP)
```

Defined in psi/mysql\_socket.h:399

Get port number and IP address of remote host that a socket is connected to. `mysql_socket_getpeername` is a replacement for `getpeername`.

#### Parameters

| Parameter | Type | Description                                                      |
| --------- | ---- | ---------------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept()  |
| `AP`      |      | Pointer to returned address of remote host in sockaddr structure |
| `LP`      |      | Pointer to length of sockaddr structure                          |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept()  |
| `AP`      |      | Pointer to returned address of remote host in sockaddr structure |
| `LP`      |      | Pointer to length of sockaddr structure                          |

***

### mysql\_socket\_send

```cpp
#define mysql_socket_send(FD, B, N, FL, FD, B, N, FL) inline_mysql_socket_send(__FILE__, __LINE__, FD, B, N, FL)
```

Defined in psi/mysql\_socket.h:416

Send data from the buffer, B, to a connected socket. `mysql_socket_send` is a replacement for `send`.

#### Parameters

| Parameter | Type | Description                                                     |
| --------- | ---- | --------------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |
| `B`       |      | Buffer to send                                                  |
| `N`       |      | Number of bytes to send                                         |
| `FL`      |      | Control flags                                                   |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |
| `B`       |      | Buffer to send                                                  |
| `N`       |      | Number of bytes to send                                         |
| `FL`      |      | Control flags                                                   |

***

### mysql\_socket\_recv

```cpp
#define mysql_socket_recv(FD, B, N, FL, FD, B, N, FL) inline_mysql_socket_recv(__FILE__, __LINE__, FD, B, N, FL)
```

Defined in psi/mysql\_socket.h:433

Receive data from a connected socket. `mysql_socket_recv` is a replacement for `recv`.

#### Parameters

| Parameter | Type | Description                                                     |
| --------- | ---- | --------------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |
| `B`       |      | Buffer to receive to                                            |
| `N`       |      | Maximum bytes to receive                                        |
| `FL`      |      | Control flags                                                   |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |
| `B`       |      | Buffer to receive to                                            |
| `N`       |      | Maximum bytes to receive                                        |
| `FL`      |      | Control flags                                                   |

***

### mysql\_socket\_sendto

```cpp
#define mysql_socket_sendto(FD, B, N, FL, AP, L, FD, B, N, FL, AP, L) inline_mysql_socket_sendto(__FILE__, __LINE__, FD, B, N, FL, AP, L)
```

Defined in psi/mysql\_socket.h:452

Send data to a socket at the specified address. `mysql_socket_sendto` is a replacement for `sendto`.

#### Parameters

| Parameter | Type | Description                                         |
| --------- | ---- | --------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket() |
| `B`       |      | Buffer to send                                      |
| `N`       |      | Number of bytes to send                             |
| `FL`      |      | Control flags                                       |
| `AP`      |      | Pointer to destination sockaddr structure           |
| `L`       |      | Size of sockaddr structure                          |
| `FD`      |      | Instrumented socket descriptor returned by socket() |
| `B`       |      | Buffer to send                                      |
| `N`       |      | Number of bytes to send                             |
| `FL`      |      | Control flags                                       |
| `AP`      |      | Pointer to destination sockaddr structure           |
| `L`       |      | Size of sockaddr structure                          |

***

### mysql\_socket\_recvfrom

```cpp
#define mysql_socket_recvfrom(FD, B, N, FL, AP, LP, FD, B, N, FL, AP, LP) inline_mysql_socket_recvfrom(__FILE__, __LINE__, FD, B, N, FL, AP, LP)
```

Defined in psi/mysql\_socket.h:471

Receive data from a socket and return source address information `mysql_socket_recvfrom` is a replacement for `recvfrom`.

#### Parameters

| Parameter | Type | Description                                              |
| --------- | ---- | -------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket()      |
| `B`       |      | Buffer to receive to                                     |
| `N`       |      | Maximum bytes to receive                                 |
| `FL`      |      | Control flags                                            |
| `AP`      |      | Pointer to source address in sockaddr\_storage structure |
| `LP`      |      | Size of sockaddr\_storage structure                      |
| `FD`      |      | Instrumented socket descriptor returned by socket()      |
| `B`       |      | Buffer to receive to                                     |
| `N`       |      | Maximum bytes to receive                                 |
| `FL`      |      | Control flags                                            |
| `AP`      |      | Pointer to source address in sockaddr\_storage structure |
| `LP`      |      | Size of sockaddr\_storage structure                      |

***

### mysql\_socket\_getsockopt

```cpp
#define mysql_socket_getsockopt(FD, LV, ON, OP, OL, FD, LV, ON, OP, OL) inline_mysql_socket_getsockopt(__FILE__, __LINE__, FD, LV, ON, OP, OL)
```

Defined in psi/mysql\_socket.h:489

Get a socket option for the specified socket. `mysql_socket_getsockopt` is a replacement for `getsockopt`.

#### Parameters

| Parameter | Type | Description                                                  |
| --------- | ---- | ------------------------------------------------------------ |
| `FD`      |      | Instrumented socket descriptor returned by socket()          |
| `LV`      |      | Protocol level                                               |
| `ON`      |      | Option to query                                              |
| `OP`      |      | Buffer which will contain the value for the requested option |
| `OL`      |      | Pointer to length of OP                                      |
| `FD`      |      | Instrumented socket descriptor returned by socket()          |
| `LV`      |      | Protocol level                                               |
| `ON`      |      | Option to query                                              |
| `OP`      |      | Buffer which will contain the value for the requested option |
| `OL`      |      | Pointer to length of OP                                      |

***

### mysql\_socket\_setsockopt

```cpp
#define mysql_socket_setsockopt(FD, LV, ON, OP, OL, FD, LV, ON, OP, OL) inline_mysql_socket_setsockopt(__FILE__, __LINE__, FD, LV, ON, OP, OL)
```

Defined in psi/mysql\_socket.h:507

Set a socket option for the specified socket. `mysql_socket_setsockopt` is a replacement for `setsockopt`.

#### Parameters

| Parameter | Type | Description                                          |
| --------- | ---- | ---------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket()  |
| `LV`      |      | Protocol level                                       |
| `ON`      |      | Option to modify                                     |
| `OP`      |      | Buffer containing the value for the specified option |
| `OL`      |      | Pointer to length of OP                              |
| `FD`      |      | Instrumented socket descriptor returned by socket()  |
| `LV`      |      | Protocol level                                       |
| `ON`      |      | Option to modify                                     |
| `OP`      |      | Buffer containing the value for the specified option |
| `OL`      |      | Pointer to length of OP                              |

***

### mysql\_sock\_set\_nonblocking

```cpp
#define mysql_sock_set_nonblocking(FD, FD) inline_mysql_sock_set_nonblocking(__FILE__, __LINE__, FD)
```

Defined in psi/mysql\_socket.h:520

Set socket to non-blocking.

#### Parameters

| Parameter | Type | Description                    |
| --------- | ---- | ------------------------------ |
| `FD`      |      | instrumented socket descriptor |
| `FD`      |      | instrumented socket descriptor |

***

### mysql\_socket\_listen

```cpp
#define mysql_socket_listen(FD, N, FD, N) inline_mysql_socket_listen(__FILE__, __LINE__, FD, N)
```

Defined in psi/mysql\_socket.h:535

Set socket state to listen for an incoming connection. `mysql_socket_listen` is a replacement for `listen`.

#### Parameters

| Parameter | Type | Description                                         |
| --------- | ---- | --------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor, bound and connected |
| `N`       |      | Maximum number of pending connections allowed.      |
| `FD`      |      | Instrumented socket descriptor, bound and connected |
| `N`       |      | Maximum number of pending connections allowed.      |

***

### mysql\_socket\_accept

```cpp
#define mysql_socket_accept(K, FD, AP, LP, K, FD, AP, LP) inline_mysql_socket_accept(__FILE__, __LINE__, K, FD, AP, LP)
```

Defined in psi/mysql\_socket.h:552

Accept a connection from any remote host; TCP only. `mysql_socket_accept` is a replacement for `accept`.

#### Parameters

| Parameter | Type | Description                                                                       |
| --------- | ---- | --------------------------------------------------------------------------------- |
| `K`       |      | PSI\_socket\_key for this instrumented socket                                     |
| `FD`      |      | Instrumented socket descriptor, bound and placed in a listen state                |
| `AP`      |      | Pointer to sockaddr structure with returned IP address and port of connected host |
| `LP`      |      | Pointer to length of valid information in AP                                      |
| `K`       |      | PSI\_socket\_key for this instrumented socket                                     |
| `FD`      |      | Instrumented socket descriptor, bound and placed in a listen state                |
| `AP`      |      | Pointer to sockaddr structure with returned IP address and port of connected host |
| `LP`      |      | Pointer to length of valid information in AP                                      |

***

### mysql\_socket\_close

```cpp
#define mysql_socket_close(FD, FD) inline_mysql_socket_close(__FILE__, __LINE__, FD)
```

Defined in psi/mysql\_socket.h:566

Close a socket and sever any connections. `mysql_socket_close` is a replacement for `close`.

#### Parameters

| Parameter | Type | Description                                                     |
| --------- | ---- | --------------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |

***

### mysql\_socket\_shutdown

```cpp
#define mysql_socket_shutdown(FD, H, FD, H) inline_mysql_socket_shutdown(__FILE__, __LINE__, FD, H)
```

Defined in psi/mysql\_socket.h:581

Disable receives and/or sends on a socket. `mysql_socket_shutdown` is a replacement for `shutdown`.

#### Parameters

| Parameter | Type | Description                                                     |
| --------- | ---- | --------------------------------------------------------------- |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |
| `H`       |      | Specifies which operations to shutdown                          |
| `FD`      |      | Instrumented socket descriptor returned by socket() or accept() |
| `H`       |      | Specifies which operations to shutdown                          |

***

### PSI\_MUTEX\_CALL

```cpp
#define PSI_MUTEX_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_thread.h:73

***

### PSI\_RWLOCK\_CALL

```cpp
#define PSI_RWLOCK_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_thread.h:77

***

### PSI\_COND\_CALL

```cpp
#define PSI_COND_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_thread.h:81

***

### PSI\_THREAD\_CALL

```cpp
#define PSI_THREAD_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_thread.h:85

***

### PSI\_CALL\_delete\_current\_thread

```cpp
#define PSI_CALL_delete_current_thread() do { } while(0)
```

Defined in psi/mysql\_thread.h:111

***

### PSI\_CALL\_get\_thread

```cpp
#define PSI_CALL_get_thread() NULL
```

Defined in psi/mysql\_thread.h:112

***

### PSI\_CALL\_new\_thread

```cpp
#define PSI_CALL_new_thread(A1, A2, A3, A1, A2, A3) NULL
```

Defined in psi/mysql\_thread.h:113

***

### PSI\_CALL\_register\_thread

```cpp
#define PSI_CALL_register_thread(A1, A2, A3, A1, A2, A3) do { } while(0)
```

Defined in psi/mysql\_thread.h:114

***

### PSI\_CALL\_set\_thread

```cpp
#define PSI_CALL_set_thread(A1, A1) do { } while(0)
```

Defined in psi/mysql\_thread.h:115

***

### PSI\_CALL\_set\_thread\_THD

```cpp
#define PSI_CALL_set_thread_THD(A1, A2, A1, A2) do { } while(0)
```

Defined in psi/mysql\_thread.h:116

***

### PSI\_CALL\_set\_thread\_connect\_attrs

```cpp
#define PSI_CALL_set_thread_connect_attrs(A1, A2, A3, A1, A2, A3) 0
```

Defined in psi/mysql\_thread.h:117

***

### PSI\_CALL\_set\_thread\_db

```cpp
#define PSI_CALL_set_thread_db(A1, A2, A1, A2) do { } while(0)
```

Defined in psi/mysql\_thread.h:118

***

### PSI\_CALL\_set\_thread\_id

```cpp
#define PSI_CALL_set_thread_id(A1, A2, A1, A2) do { } while(0)
```

Defined in psi/mysql\_thread.h:119

***

### PSI\_CALL\_set\_thread\_os\_id

```cpp
#define PSI_CALL_set_thread_os_id(A1, A1) do { } while(0)
```

Defined in psi/mysql\_thread.h:120

***

### PSI\_CALL\_set\_thread\_info

```cpp
#define PSI_CALL_set_thread_info(A1, A2, A1, A2) do { } while(0)
```

Defined in psi/mysql\_thread.h:121

***

### PSI\_CALL\_set\_thread\_start\_time

```cpp
#define PSI_CALL_set_thread_start_time(A1, A1) do { } while(0)
```

Defined in psi/mysql\_thread.h:122

***

### PSI\_CALL\_set\_thread\_account

```cpp
#define PSI_CALL_set_thread_account(A1, A2, A3, A4, A1, A2, A3, A4) do { } while(0)
```

Defined in psi/mysql\_thread.h:123

***

### PSI\_CALL\_spawn\_thread

```cpp
#define PSI_CALL_spawn_thread(A1, A2, A3, A4, A5, A1, A2, A3, A4, A5) 0
```

Defined in psi/mysql\_thread.h:124

***

### PSI\_CALL\_set\_connection\_type

```cpp
#define PSI_CALL_set_connection_type(A, A) do { } while(0)
```

Defined in psi/mysql\_thread.h:125

***

### mysql\_mutex\_is\_owner

```cpp
#define mysql_mutex_is_owner(M, M) safe_mutex_is_owner(&(M)->m_mutex)
```

Defined in psi/mysql\_thread.h:266

***

### mysql\_mutex\_assert\_owner

```cpp
#define mysql_mutex_assert_owner(M, M) safe_mutex_assert_owner(&(M)->m_mutex)
```

Defined in psi/mysql\_thread.h:273

Wrapper, to use safe\_mutex\_assert\_owner with instrumented mutexes. `mysql_mutex_assert_owner` is a drop-in replacement for `safe_mutex_assert_owner`.

***

### mysql\_mutex\_assert\_not\_owner

```cpp
#define mysql_mutex_assert_not_owner(M, M) safe_mutex_assert_not_owner(&(M)->m_mutex)
```

Defined in psi/mysql\_thread.h:282

Wrapper, to use safe\_mutex\_assert\_not\_owner with instrumented mutexes. `mysql_mutex_assert_not_owner` is a drop-in replacement for `safe_mutex_assert_not_owner`.

***

### mysql\_mutex\_setflags

```cpp
#define mysql_mutex_setflags(M, F, M, F) safe_mutex_setflags(&(M)->m_mutex, (F))
```

Defined in psi/mysql\_thread.h:285

***

### mysql\_prlock\_assert\_write\_owner

```cpp
#define mysql_prlock_assert_write_owner(M, M) rw_pr_lock_assert_write_owner(&(M)->m_prlock)
```

Defined in psi/mysql\_thread.h:293

Drop-in replacement for `rw_pr_lock_assert_write_owner`.

***

### mysql\_prlock\_assert\_not\_write\_owner

```cpp
#define mysql_prlock_assert_not_write_owner(M, M) rw_pr_lock_assert_not_write_owner(&(M)->m_prlock)
```

Defined in psi/mysql\_thread.h:301

Drop-in replacement for `rw_pr_lock_assert_not_write_owner`.

***

### mysql\_mutex\_register

```cpp
#define mysql_mutex_register(P1, P2, P3, P1, P2, P3) inline_mysql_mutex_register(P1, P2, P3)
```

Defined in psi/mysql\_thread.h:308

Mutex registration.

***

### mysql\_mutex\_init

```cpp
#define mysql_mutex_init(K, M, A, K, M, A) inline_mysql_mutex_init(M, A)
```

Defined in psi/mysql\_thread.h:333

Instrumented mutex\_init. `mysql_mutex_init` is a replacement for `pthread_mutex_init`.

#### Parameters

| Parameter | Type | Description                                     |
| --------- | ---- | ----------------------------------------------- |
| `K`       |      | The PSI\_mutex\_key for this instrumented mutex |
| `M`       |      | The mutex to initialize                         |
| `A`       |      | Mutex attributes                                |
| `K`       |      | The PSI\_mutex\_key for this instrumented mutex |
| `M`       |      | The mutex to initialize                         |
| `A`       |      | Mutex attributes                                |

***

### mysql\_mutex\_destroy

```cpp
#define mysql_mutex_destroy(M, M) inline_mysql_mutex_destroy(M)
```

Defined in psi/mysql\_thread.h:348

Instrumented mutex\_destroy. `mysql_mutex_destroy` is a drop-in replacement for `pthread_mutex_destroy`.

***

### mysql\_mutex\_lock

```cpp
#define mysql_mutex_lock(M, M) inline_mysql_mutex_lock(M)
```

Defined in psi/mysql\_thread.h:363

Instrumented mutex\_lock. `mysql_mutex_lock` is a drop-in replacement for `pthread_mutex_lock`.

#### Parameters

| Parameter | Type | Description       |
| --------- | ---- | ----------------- |
| `M`       |      | The mutex to lock |
| `M`       |      | The mutex to lock |

***

### mysql\_mutex\_trylock

```cpp
#define mysql_mutex_trylock(M, M) inline_mysql_mutex_trylock(M)
```

Defined in psi/mysql\_thread.h:378

Instrumented mutex\_lock. `mysql_mutex_trylock` is a drop-in replacement for `pthread_mutex_trylock`.

***

### mysql\_mutex\_unlock

```cpp
#define mysql_mutex_unlock(M, M) inline_mysql_mutex_unlock(M)
```

Defined in psi/mysql\_thread.h:391

Instrumented mutex\_unlock. `mysql_mutex_unlock` is a drop-in replacement for `pthread_mutex_unlock`.

***

### mysql\_rwlock\_register

```cpp
#define mysql_rwlock_register(P1, P2, P3, P1, P2, P3) inline_mysql_rwlock_register(P1, P2, P3)
```

Defined in psi/mysql\_thread.h:399

Rwlock registration.

***

### mysql\_rwlock\_init

```cpp
#define mysql_rwlock_init(K, RW, K, RW) inline_mysql_rwlock_init(RW)
```

Defined in psi/mysql\_thread.h:413

Instrumented rwlock\_init. `mysql_rwlock_init` is a replacement for `pthread_rwlock_init`. Note that pthread\_rwlockattr\_t is not supported in MySQL.

#### Parameters

| Parameter | Type | Description                                       |
| --------- | ---- | ------------------------------------------------- |
| `K`       |      | The PSI\_rwlock\_key for this instrumented rwlock |
| `RW`      |      | The rwlock to initialize                          |
| `K`       |      | The PSI\_rwlock\_key for this instrumented rwlock |
| `RW`      |      | The rwlock to initialize                          |

***

### mysql\_prlock\_init

```cpp
#define mysql_prlock_init(K, RW, K, RW) inline_mysql_prlock_init(RW)
```

Defined in psi/mysql\_thread.h:426

Instrumented rw\_pr\_init. `mysql_prlock_init` is a replacement for `rw_pr_init`.

#### Parameters

| Parameter | Type | Description                                       |
| --------- | ---- | ------------------------------------------------- |
| `K`       |      | The PSI\_rwlock\_key for this instrumented prlock |
| `RW`      |      | The prlock to initialize                          |
| `K`       |      | The PSI\_rwlock\_key for this instrumented prlock |
| `RW`      |      | The prlock to initialize                          |

***

### mysql\_rwlock\_destroy

```cpp
#define mysql_rwlock_destroy(RW, RW) inline_mysql_rwlock_destroy(RW)
```

Defined in psi/mysql\_thread.h:435

Instrumented rwlock\_destroy. `mysql_rwlock_destroy` is a drop-in replacement for `pthread_rwlock_destroy`.

***

### mysql\_prlock\_destroy

```cpp
#define mysql_prlock_destroy(RW, RW) inline_mysql_prlock_destroy(RW)
```

Defined in psi/mysql\_thread.h:443

Instrumented rw\_pr\_destroy. `mysql_prlock_destroy` is a drop-in replacement for `rw_pr_destroy`.

***

### mysql\_rwlock\_rdlock

```cpp
#define mysql_rwlock_rdlock(RW, RW) inline_mysql_rwlock_rdlock(RW)
```

Defined in psi/mysql\_thread.h:455

Instrumented rwlock\_rdlock. `mysql_rwlock_rdlock` is a drop-in replacement for `pthread_rwlock_rdlock`.

***

### mysql\_prlock\_rdlock

```cpp
#define mysql_prlock_rdlock(RW, RW) inline_mysql_prlock_rdlock(RW)
```

Defined in psi/mysql\_thread.h:469

Instrumented rw\_pr\_rdlock. `mysql_prlock_rdlock` is a drop-in replacement for `rw_pr_rdlock`.

***

### mysql\_rwlock\_wrlock

```cpp
#define mysql_rwlock_wrlock(RW, RW) inline_mysql_rwlock_wrlock(RW)
```

Defined in psi/mysql\_thread.h:483

Instrumented rwlock\_wrlock. `mysql_rwlock_wrlock` is a drop-in replacement for `pthread_rwlock_wrlock`.

***

### mysql\_prlock\_wrlock

```cpp
#define mysql_prlock_wrlock(RW, RW) inline_mysql_prlock_wrlock(RW)
```

Defined in psi/mysql\_thread.h:497

Instrumented rw\_pr\_wrlock. `mysql_prlock_wrlock` is a drop-in replacement for `rw_pr_wrlock`.

***

### mysql\_rwlock\_tryrdlock

```cpp
#define mysql_rwlock_tryrdlock(RW, RW) inline_mysql_rwlock_tryrdlock(RW)
```

Defined in psi/mysql\_thread.h:511

Instrumented rwlock\_tryrdlock. `mysql_rwlock_tryrdlock` is a drop-in replacement for `pthread_rwlock_tryrdlock`.

***

### mysql\_rwlock\_trywrlock

```cpp
#define mysql_rwlock_trywrlock(RW, RW) inline_mysql_rwlock_trywrlock(RW)
```

Defined in psi/mysql\_thread.h:525

Instrumented rwlock\_trywrlock. `mysql_rwlock_trywrlock` is a drop-in replacement for `pthread_rwlock_trywrlock`.

***

### mysql\_rwlock\_unlock

```cpp
#define mysql_rwlock_unlock(RW, RW) inline_mysql_rwlock_unlock(RW)
```

Defined in psi/mysql\_thread.h:535

Instrumented rwlock\_unlock. `mysql_rwlock_unlock` is a drop-in replacement for `pthread_rwlock_unlock`.

***

### mysql\_prlock\_unlock

```cpp
#define mysql_prlock_unlock(RW, RW) inline_mysql_prlock_unlock(RW)
```

Defined in psi/mysql\_thread.h:543

Instrumented rw\_pr\_unlock. `mysql_prlock_unlock` is a drop-in replacement for `rw_pr_unlock`.

***

### mysql\_cond\_register

```cpp
#define mysql_cond_register(P1, P2, P3, P1, P2, P3) inline_mysql_cond_register(P1, P2, P3)
```

Defined in psi/mysql\_thread.h:549

Cond registration.

***

### mysql\_cond\_init

```cpp
#define mysql_cond_init(K, C, A, K, C, A) inline_mysql_cond_init(C, A)
```

Defined in psi/mysql\_thread.h:563

Instrumented cond\_init. `mysql_cond_init` is a replacement for `pthread_cond_init`.

#### Parameters

| Parameter | Type | Description                                   |
| --------- | ---- | --------------------------------------------- |
| `K`       |      | The PSI\_cond\_key for this instrumented cond |
| `C`       |      | The cond to initialize                        |
| `A`       |      | Condition attributes                          |
| `K`       |      | The PSI\_cond\_key for this instrumented cond |
| `C`       |      | The cond to initialize                        |
| `A`       |      | Condition attributes                          |

***

### mysql\_cond\_destroy

```cpp
#define mysql_cond_destroy(C, C) inline_mysql_cond_destroy(C)
```

Defined in psi/mysql\_thread.h:571

Instrumented cond\_destroy. `mysql_cond_destroy` is a drop-in replacement for `pthread_cond_destroy`.

***

### mysql\_cond\_wait

```cpp
#define mysql_cond_wait(C, M, C, M) inline_mysql_cond_wait(C, M)
```

Defined in psi/mysql\_thread.h:582

Instrumented cond\_wait. `mysql_cond_wait` is a drop-in replacement for `pthread_cond_wait`.

***

### mysql\_cond\_timedwait

```cpp
#define mysql_cond_timedwait(C, M, W, C, M, W) inline_mysql_cond_timedwait(C, M, W)
```

Defined in psi/mysql\_thread.h:596

Instrumented cond\_timedwait. `mysql_cond_timedwait` is a drop-in replacement for `pthread_cond_timedwait`.

***

### mysql\_cond\_signal

```cpp
#define mysql_cond_signal(C, C) inline_mysql_cond_signal(C)
```

Defined in psi/mysql\_thread.h:605

Instrumented cond\_signal. `mysql_cond_signal` is a drop-in replacement for `pthread_cond_signal`.

***

### mysql\_cond\_broadcast

```cpp
#define mysql_cond_broadcast(C, C) inline_mysql_cond_broadcast(C)
```

Defined in psi/mysql\_thread.h:613

Instrumented cond\_broadcast. `mysql_cond_broadcast` is a drop-in replacement for `pthread_cond_broadcast`.

***

### mysql\_thread\_register

```cpp
#define mysql_thread_register(P1, P2, P3, P1, P2, P3) inline_mysql_thread_register(P1, P2, P3)
```

Defined in psi/mysql\_thread.h:619

Thread registration.

***

### mysql\_thread\_create

```cpp
#define mysql_thread_create(K, P1, P2, P3, P4, K, P1, P2, P3, P4) pthread_create(P1, P2, P3, P4)
```

Defined in psi/mysql\_thread.h:643

Instrumented pthread\_create. This function creates both the thread instrumentation and a thread. `mysql_thread_create` is a replacement for `pthread_create`. The parameter P4 (or, if it is NULL, P1) will be used as the instrumented thread "identity". Providing a P1 / P4 parameter with a different value for each call will on average improve performances, since this thread identity value is used internally to randomize access to data and prevent contention. This is optional, and the improvement is not guaranteed, only statistical.

#### Parameters

| Parameter | Type | Description                                       |
| --------- | ---- | ------------------------------------------------- |
| `K`       |      | The PSI\_thread\_key for this instrumented thread |
| `P1`      |      | pthread\_create parameter 1                       |
| `P2`      |      | pthread\_create parameter 2                       |
| `P3`      |      | pthread\_create parameter 3                       |
| `P4`      |      | pthread\_create parameter 4                       |
| `K`       |      | The PSI\_thread\_key for this instrumented thread |
| `P1`      |      | pthread\_create parameter 1                       |
| `P2`      |      | pthread\_create parameter 2                       |
| `P3`      |      | pthread\_create parameter 3                       |
| `P4`      |      | pthread\_create parameter 4                       |

***

### mysql\_thread\_set\_psi\_id

```cpp
#define mysql_thread_set_psi_id(I, I) do {} while (0)
```

Defined in psi/mysql\_thread.h:655

Set the thread identifier for the instrumentation.

#### Parameters

| Parameter | Type | Description           |
| --------- | ---- | --------------------- |
| `I`       |      | The thread identifier |
| `I`       |      | The thread identifier |

***

### mysql\_thread\_set\_psi\_THD

```cpp
#define mysql_thread_set_psi_THD(T, T) do {} while (0)
```

Defined in psi/mysql\_thread.h:666

Set the thread sql session for the instrumentation.

#### Parameters

| Parameter | Type | Description           |
| --------- | ---- | --------------------- |
| `T`       |      | The thread identifier |
| `T`       |      | The thread identifier |

***

### MY\_SHA1\_HASH\_SIZE

```cpp
#define MY_SHA1_HASH_SIZE 20 /* Hash size in bytes */
```

Defined in service\_sha1.h:32

***

### MYSQL\_SERVICE\_SHA1\_INCLUDED

```cpp
#define MYSQL_SERVICE_SHA1_INCLUDED
```

Defined in service\_sha1.h:67

***

### MYSQL\_SERVICE\_SHA2\_INCLUDED

```cpp
#define MYSQL_SERVICE_SHA2_INCLUDED
```

Defined in service\_sha2.h:128

***

### MYSQL\_CLIENT\_PLUGIN\_INCLUDED

```cpp
#define MYSQL_CLIENT_PLUGIN_INCLUDED
```

Defined in client\_plugin.h:25

***

### MYSQL\_PLUGIN\_EXPORT\_C

```cpp
#define MYSQL_PLUGIN_EXPORT_C
```

Defined in client\_plugin.h:37

***

### MYSQL\_PLUGIN\_EXPORT

```cpp
#define MYSQL_PLUGIN_EXPORT MYSQL_PLUGIN_EXPORT_C
```

Defined in client\_plugin.h:44

***

### C\_MODE\_START

```cpp
#define C_MODE_START
```

Defined in client\_plugin.h:45

***

### C\_MODE\_END

```cpp
#define C_MODE_END
```

Defined in client\_plugin.h:46

***

### MYSQL\_CLIENT\_reserved1

```cpp
#define MYSQL_CLIENT_reserved1 0
```

Defined in client\_plugin.h:55

***

### MYSQL\_CLIENT\_reserved2

```cpp
#define MYSQL_CLIENT_reserved2 1
```

Defined in client\_plugin.h:56

***

### MYSQL\_CLIENT\_AUTHENTICATION\_PLUGIN

```cpp
#define MYSQL_CLIENT_AUTHENTICATION_PLUGIN 2
```

Defined in client\_plugin.h:57

***

### MYSQL\_CLIENT\_AUTHENTICATION\_PLUGIN\_INTERFACE\_VERSION

```cpp
#define MYSQL_CLIENT_AUTHENTICATION_PLUGIN_INTERFACE_VERSION 0x0101
```

Defined in client\_plugin.h:59

***

### MYSQL\_CLIENT\_MAX\_PLUGINS

```cpp
#define MYSQL_CLIENT_MAX_PLUGINS 3
```

Defined in client\_plugin.h:61

***

### mysql\_declare\_client\_plugin

```cpp
#define mysql_declare_client_plugin(X) C_MODE_STARTMYSQL_PLUGIN_EXPORT_C         \
        struct st_mysql_client_plugin_ ## X        \
        _mysql_client_plugin_declaration_ = {   \
          MYSQL_CLIENT_ ## X ## _PLUGIN,        \
          MYSQL_CLIENT_ ## X ## _PLUGIN_INTERFACE_VERSION,
```

Defined in client\_plugin.h:63

***

### mysql\_end\_client\_plugin

```cpp
#define mysql_end_client_plugin }; C_MODE_END
```

Defined in client\_plugin.h:69

***

### MYSQL\_CLIENT\_PLUGIN\_HEADER

```cpp
#define MYSQL_CLIENT_PLUGIN_HEADER int type;                                             \
  unsigned int interface_version;                       \
  const char *name;                                     \
  const char *author;                                   \
  const char *desc;                                     \
  unsigned int version[3];                              \
  const char *license;                                  \
  void *mysql_api;                                      \
  int (*init)(char *, size_t, int, va_list);            \
  int (*deinit)();                                      \
  int (*options)(const char *option, const void *);
```

Defined in client\_plugin.h:72

***

### WSREP\_ASSERT\_INNODB\_TRX

```cpp
#define WSREP_ASSERT_INNODB_TRX 1
```

Defined in service\_wsrep.h:14

***

### MYSQL\_SERVICE\_WSREP\_INCLUDED

```cpp
#define MYSQL_SERVICE_WSREP_INCLUDED
```

Defined in service\_wsrep.h:107

***

### MYSQL\_SERVICE\_WSREP\_STATIC\_INCLUDED

```cpp
#define MYSQL_SERVICE_WSREP_STATIC_INCLUDED
```

Defined in service\_wsrep.h:158

***

### MY\_BASE64\_DECODE\_ALLOW\_MULTIPLE\_CHUNKS

```cpp
#define MY_BASE64_DECODE_ALLOW_MULTIPLE_CHUNKS 1
```

Defined in service\_base64.h:33

***

### MYSQL\_SERVICE\_BASE64\_INCLUDED

```cpp
#define MYSQL_SERVICE_BASE64_INCLUDED
```

Defined in service\_base64.h:81

***

### MYSQL\_FTPARSER\_INTERFACE\_VERSION

```cpp
#define MYSQL_FTPARSER_INTERFACE_VERSION 0x0100
```

Defined in plugin\_ftparser.h:29

***

### MYSQL\_FTFLAGS\_NEED\_COPY

```cpp
#define MYSQL_FTFLAGS_NEED_COPY 1
```

Defined in plugin\_ftparser.h:142

***

### PSI\_STATEMENT\_CALL

```cpp
#define PSI_STATEMENT_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_statement.h:38

***

### PSI\_DIGEST\_CALL

```cpp
#define PSI_DIGEST_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_statement.h:42

***

### mysql\_statement\_register

```cpp
#define mysql_statement_register(P1, P2, P3, P1, P2, P3) do {} while (0)
```

Defined in psi/mysql\_statement.h:59

Statement registration.

***

### MYSQL\_DIGEST\_START

```cpp
#define MYSQL_DIGEST_START(LOCKER, LOCKER) NULL
```

Defined in psi/mysql\_statement.h:67

***

### MYSQL\_DIGEST\_END

```cpp
#define MYSQL_DIGEST_END(LOCKER, DIGEST, LOCKER, DIGEST) do {} while (0)
```

Defined in psi/mysql\_statement.h:75

***

### MYSQL\_START\_STATEMENT

```cpp
#define MYSQL_START_STATEMENT(STATE, K, DB, DB_LEN, CS, SPS, STATE, K, DB, DB_LEN, CS, SPS) NULL
```

Defined in psi/mysql\_statement.h:83

***

### MYSQL\_REFINE\_STATEMENT

```cpp
#define MYSQL_REFINE_STATEMENT(LOCKER, K, LOCKER, K) NULL
```

Defined in psi/mysql\_statement.h:91

***

### MYSQL\_SET\_STATEMENT\_TEXT

```cpp
#define MYSQL_SET_STATEMENT_TEXT(LOCKER, P1, P2, LOCKER, P1, P2) do {} while (0)
```

Defined in psi/mysql\_statement.h:99

***

### MYSQL\_SET\_STATEMENT\_LOCK\_TIME

```cpp
#define MYSQL_SET_STATEMENT_LOCK_TIME(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_statement.h:107

***

### MYSQL\_SET\_STATEMENT\_ROWS\_SENT

```cpp
#define MYSQL_SET_STATEMENT_ROWS_SENT(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_statement.h:115

***

### MYSQL\_SET\_STATEMENT\_ROWS\_EXAMINED

```cpp
#define MYSQL_SET_STATEMENT_ROWS_EXAMINED(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_statement.h:123

***

### MYSQL\_END\_STATEMENT

```cpp
#define MYSQL_END_STATEMENT(LOCKER, DA, LOCKER, DA) do {} while (0)
```

Defined in psi/mysql\_statement.h:131

***

### MYSQL\_SERVICE\_THD\_RND\_INCLUDED

```cpp
#define MYSQL_SERVICE_THD_RND_INCLUDED
```

Defined in service\_thd\_rnd.h:62

***

### MYSQL\_PLUGIN\_ENCRYPTION\_INCLUDED

```cpp
#define MYSQL_PLUGIN_ENCRYPTION_INCLUDED
```

Defined in plugin\_encryption.h:26

***

### MariaDB\_ENCRYPTION\_INTERFACE\_VERSION

```cpp
#define MariaDB_ENCRYPTION_INTERFACE_VERSION 0x0300
```

Defined in plugin\_encryption.h:34

***

### PSI\_TRANSACTION\_CALL

```cpp
#define PSI_TRANSACTION_CALL(M) PSI_DYNAMIC_CALL(M)
```

Defined in psi/mysql\_transaction.h:34

***

### MYSQL\_START\_TRANSACTION

```cpp
#define MYSQL_START_TRANSACTION(STATE, XID, TRXID, ISO, RO, AC, STATE, XID, TRXID, ISO, RO, AC) 0
```

Defined in psi/mysql\_transaction.h:47

***

### MYSQL\_SET\_TRANSACTION\_GTID

```cpp
#define MYSQL_SET_TRANSACTION_GTID(LOCKER, P1, P2, LOCKER, P1, P2) do {} while (0)
```

Defined in psi/mysql\_transaction.h:55

***

### MYSQL\_SET\_TRANSACTION\_XID

```cpp
#define MYSQL_SET_TRANSACTION_XID(LOCKER, P1, P2, LOCKER, P1, P2) do {} while (0)
```

Defined in psi/mysql\_transaction.h:63

***

### MYSQL\_SET\_TRANSACTION\_XA\_STATE

```cpp
#define MYSQL_SET_TRANSACTION_XA_STATE(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_transaction.h:71

***

### MYSQL\_SET\_TRANSACTION\_TRXID

```cpp
#define MYSQL_SET_TRANSACTION_TRXID(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_transaction.h:79

***

### MYSQL\_INC\_TRANSACTION\_SAVEPOINTS

```cpp
#define MYSQL_INC_TRANSACTION_SAVEPOINTS(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_transaction.h:87

***

### MYSQL\_INC\_TRANSACTION\_ROLLBACK\_TO\_SAVEPOINT

```cpp
#define MYSQL_INC_TRANSACTION_ROLLBACK_TO_SAVEPOINT(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_transaction.h:95

***

### MYSQL\_INC\_TRANSACTION\_RELEASE\_SAVEPOINT

```cpp
#define MYSQL_INC_TRANSACTION_RELEASE_SAVEPOINT(LOCKER, P1, LOCKER, P1) do {} while (0)
```

Defined in psi/mysql\_transaction.h:103

***

### MYSQL\_ROLLBACK\_TRANSACTION

```cpp
#define MYSQL_ROLLBACK_TRANSACTION(LOCKER, LOCKER) do { } while(0)
```

Defined in psi/mysql\_transaction.h:111

***

### MYSQL\_COMMIT\_TRANSACTION

```cpp
#define MYSQL_COMMIT_TRANSACTION(LOCKER, LOCKER) do { } while(0)
```

Defined in psi/mysql\_transaction.h:119

***

### MY\_AES\_OK

```cpp
#define MY_AES_OK 0
```

Defined in service\_my\_crypt.h:37

***

### MY\_AES\_BAD\_DATA

```cpp
#define MY_AES_BAD_DATA -100
```

Defined in service\_my\_crypt.h:38

***

### MY\_AES\_OPENSSL\_ERROR

```cpp
#define MY_AES_OPENSSL_ERROR -101
```

Defined in service\_my\_crypt.h:39

***

### MY\_AES\_BAD\_KEYSIZE

```cpp
#define MY_AES_BAD_KEYSIZE -102
```

Defined in service\_my\_crypt.h:40

***

### MY\_AES\_BLOCK\_SIZE

```cpp
#define MY_AES_BLOCK_SIZE 16
```

Defined in service\_my\_crypt.h:43

***

### MY\_AES\_MAX\_KEY\_LENGTH

```cpp
#define MY_AES_MAX_KEY_LENGTH 32
```

Defined in service\_my\_crypt.h:46

***

### MY\_AES\_CTX\_SIZE

```cpp
#define MY_AES_CTX_SIZE 1040
```

Defined in service\_my\_crypt.h:48

***

### ENCRYPTION\_KEY\_VERSION\_INVALID

```cpp
#define ENCRYPTION_KEY_VERSION_INVALID (~(unsigned int)0)
```

Defined in service\_encryption.h:44

***

### ENCRYPTION\_KEY\_NOT\_ENCRYPTED

```cpp
#define ENCRYPTION_KEY_NOT_ENCRYPTED (0)
```

Defined in service\_encryption.h:45

***

### ENCRYPTION\_KEY\_SYSTEM\_DATA

```cpp
#define ENCRYPTION_KEY_SYSTEM_DATA 1
```

Defined in service\_encryption.h:47

***

### ENCRYPTION\_KEY\_TEMPORARY\_DATA

```cpp
#define ENCRYPTION_KEY_TEMPORARY_DATA 2
```

Defined in service\_encryption.h:48

***

### ENCRYPTION\_KEY\_BUFFER\_TOO\_SMALL

```cpp
#define ENCRYPTION_KEY_BUFFER_TOO_SMALL (100)
```

Defined in service\_encryption.h:51

***

### ENCRYPTION\_FLAG\_DECRYPT

```cpp
#define ENCRYPTION_FLAG_DECRYPT 0
```

Defined in service\_encryption.h:53

***

### ENCRYPTION\_FLAG\_ENCRYPT

```cpp
#define ENCRYPTION_FLAG_ENCRYPT 1
```

Defined in service\_encryption.h:54

***

### ENCRYPTION\_FLAG\_NOPAD

```cpp
#define ENCRYPTION_FLAG_NOPAD 2
```

Defined in service\_encryption.h:55

***

### encryption\_key\_get\_latest\_version

```cpp
#define encryption_key_get_latest_version(KI) encryption_handler.encryption_key_get_latest_version_func(KI)
```

Defined in service\_encryption.h:87

***

### encryption\_key\_get

```cpp
#define encryption_key_get(KI, KV, K, S) encryption_handler.encryption_key_get_func((KI),(KV),(K),(S))
```

Defined in service\_encryption.h:88

***

### encryption\_ctx\_size

```cpp
#define encryption_ctx_size(KI, KV) encryption_handler.encryption_ctx_size_func((KI),(KV))
```

Defined in service\_encryption.h:89

***

### encryption\_ctx\_init

```cpp
#define encryption_ctx_init(CTX, K, KL, IV, IVL, F, KI, KV) encryption_handler.encryption_ctx_init_func((CTX),(K),(KL),(IV),(IVL),(F),(KI),(KV))
```

Defined in service\_encryption.h:90

***

### encryption\_ctx\_update

```cpp
#define encryption_ctx_update(CTX, S, SL, D, DL) encryption_handler.encryption_ctx_update_func((CTX),(S),(SL),(D),(DL))
```

Defined in service\_encryption.h:91

***

### encryption\_ctx\_finish

```cpp
#define encryption_ctx_finish(CTX, D, DL) encryption_handler.encryption_ctx_finish_func((CTX),(D),(DL))
```

Defined in service\_encryption.h:92

***

### encryption\_encrypted\_length

```cpp
#define encryption_encrypted_length(SL, KI, KV) encryption_handler.encryption_encrypted_length_func((SL),(KI),(KV))
```

Defined in service\_encryption.h:93

***

### MYSQL\_SERVICE\_ENCRYPTION\_INCLUDED

```cpp
#define MYSQL_SERVICE_ENCRYPTION_INCLUDED
```

Defined in service\_encryption.h:145

***

### MYSQL\_SERVICE\_THD\_ALLOC\_INCLUDED

```cpp
#define MYSQL_SERVICE_THD_ALLOC_INCLUDED
```

Defined in service\_thd\_alloc.h:144

***

### MYSQL\_AUTH\_DIALOG\_CLIENT\_INCLUDED

```cpp
#define MYSQL_AUTH_DIALOG_CLIENT_INCLUDED
```

Defined in auth\_dialog\_client.h:25

***

### ORDINARY\_QUESTION

```cpp
#define ORDINARY_QUESTION "\2"
```

Defined in auth\_dialog\_client.h:51

first byte of the question string is the question "type". It can be an "ordinary" or a "password" question. The last bit set marks a last question in the authentication exchange.

***

### LAST\_QUESTION

```cpp
#define LAST_QUESTION "\3"
```

Defined in auth\_dialog\_client.h:52

***

### PASSWORD\_QUESTION

```cpp
#define PASSWORD_QUESTION "\4"
```

Defined in auth\_dialog\_client.h:53

***

### LAST\_PASSWORD

```cpp
#define LAST_PASSWORD "\5"
```

Defined in auth\_dialog\_client.h:54

***

### MYSQL\_PLUGIN\_AUTH\_COMMON\_INCLUDED

```cpp
#define MYSQL_PLUGIN_AUTH_COMMON_INCLUDED
```

Defined in plugin\_auth\_common.h:28

***

### MYSQL\_USERNAME\_LENGTH

```cpp
#define MYSQL_USERNAME_LENGTH 512
```

Defined in plugin\_auth\_common.h:31

the max allowed length for a user name

***

### CR\_AUTH\_PLUGIN\_ERROR

```cpp
#define CR_AUTH_PLUGIN_ERROR 3
```

Defined in plugin\_auth\_common.h:43

return values of the plugin authenticate\_user() method. Authentication failed, plugin internal error. An error occurred in the authentication plugin itself. These errors are reported in table performance\_schema.host\_cache, column COUNT\_AUTH\_PLUGIN\_ERRORS.

***

### CR\_AUTH\_HANDSHAKE

```cpp
#define CR_AUTH_HANDSHAKE 2
```

Defined in plugin\_auth\_common.h:50

Authentication failed, client server handshake. An error occurred during the client server handshake. These errors are reported in table performance\_schema.host\_cache, column COUNT\_HANDSHAKE\_ERRORS.

***

### CR\_AUTH\_USER\_CREDENTIALS

```cpp
#define CR_AUTH_USER_CREDENTIALS 1
```

Defined in plugin\_auth\_common.h:57

Authentication failed, user credentials. For example, wrong passwords. These errors are reported in table performance\_schema.host\_cache, column COUNT\_AUTHENTICATION\_ERRORS.

***

### CR\_ERROR

```cpp
#define CR_ERROR 0
```

Defined in plugin\_auth\_common.h:68

Authentication failed. Additionally, all other CR\_xxx values (libmysql error code) can be used too.

The client plugin may set the error code and the error message directly in the MYSQL structure and return CR\_ERROR. If a CR\_xxx specific error code was returned, an error message in the MYSQL structure will be overwritten. If CR\_ERROR is returned without setting the error in MYSQL, CR\_UNKNOWN\_ERROR will be user.

***

### CR\_OK

```cpp
#define CR_OK -1
```

Defined in plugin\_auth\_common.h:76

Authentication (client part) was successful. It does not mean that the authentication as a whole was successful, usually it only means that the client was able to send the user name and the password to the server. If CR\_OK is returned, the libmysql reads the next packet expecting it to be one of OK, ERROR, or CHANGE\_PLUGIN packets.

***

### CR\_OK\_HANDSHAKE\_COMPLETE

```cpp
#define CR_OK_HANDSHAKE_COMPLETE -2
```

Defined in plugin\_auth\_common.h:91

Authentication was successful. It means that the client has done its part successfully and also that a plugin has read the last packet (one of OK, ERROR, CHANGE\_PLUGIN). In this case, libmysql will not read a packet from the server, but it will use the data at mysql->net.read\_pos.

A plugin may return this value if the number of roundtrips in the authentication protocol is not known in advance, and the client plugin needs to read one packet more to determine if the authentication is finished or not.

Server plugins should not return this value.

***

### debug\_sync\_service

```cpp
#define debug_sync_service debug_sync_C_callback_ptr
```

Defined in service\_debug\_sync.h:332

***

### DEBUG\_SYNC

```cpp
#define DEBUG_SYNC(thd, name) do { } while(0)
```

Defined in service\_debug\_sync.h:349

***

### DEBUG\_SYNC\_C\_IF\_THD

```cpp
#define DEBUG_SYNC_C_IF_THD(thd, _sync_point_name_) do { } while(0)
```

Defined in service\_debug\_sync.h:350

***

### DEBUG\_SYNC\_C

```cpp
#define DEBUG_SYNC_C(name) DEBUG_SYNC(NULL, name)
```

Defined in service\_debug\_sync.h:357

***

### MYSQL\_SERVICE\_DEBUG\_SYNC\_INCLUDED

```cpp
#define MYSQL_SERVICE_DEBUG_SYNC_INCLUDED
```

Defined in service\_debug\_sync.h:364

***

### MYSQL\_SERVICE\_MY\_SNPRINTF\_INCLUDED

```cpp
#define MYSQL_SERVICE_MY_SNPRINTF_INCLUDED
```

Defined in service\_my\_snprintf.h:124

***

### MYSQL\_SERVICE\_THD\_AUTOINC\_INCLUDED

```cpp
#define MYSQL_SERVICE_THD_AUTOINC_INCLUDED
```

Defined in service\_thd\_autoinc.h:52

***

### MYSQL\_SERVICE\_THD\_TIMEZONE\_INCLUDED

```cpp
#define MYSQL_SERVICE_THD_TIMEZONE_INCLUDED
```

Defined in service\_thd\_timezone.h:77

***

### thd\_key\_create\_from\_var

```cpp
#define thd_key_create_from_var(K, V) do { *(K)= MYSQL_SYSVAR_NAME(V).offset; } while(0)
```

Defined in service\_thd\_specifics.h:69

***

### MYSQL\_SERVICE\_THD\_SPECIFICS\_INCLUDED

```cpp
#define MYSQL_SERVICE_THD_SPECIFICS_INCLUDED
```

Defined in service\_thd\_specifics.h:108

***

### thd\_killed

```cpp
#define thd_killed(THD) (thd_kill_level(THD) == THD_ABORT_ASAP)
```

Defined in service\_kill\_statement.h:53

***

### ME\_ERROR\_LOG

```cpp
#define ME_ERROR_LOG 64 /* Write the message to the error log */
```

Defined in service\_my\_print\_error.h:36

***

### ME\_ERROR\_LOG\_ONLY

```cpp
#define ME_ERROR_LOG_ONLY 128 /* Write the error message to error log only */
```

Defined in service\_my\_print\_error.h:37

***

### ME\_NOTE

```cpp
#define ME_NOTE 1024 /* Not an error, just a note */
```

Defined in service\_my\_print\_error.h:38

***

### ME\_WARNING

```cpp
#define ME_WARNING 2048 /* Not an error, just a warning */
```

Defined in service\_my\_print\_error.h:39

***

### ME\_FATAL

```cpp
#define ME_FATAL 4096 /* Fatal statement error */
```

Defined in service\_my\_print\_error.h:40

***

### thd\_proc\_info

```cpp
#define thd_proc_info(thd, msg) set_thd_proc_info(thd, msg, \
                                                   __func__, __FILE__, __LINE__)
```

Defined in service\_progress\_report.h:32

***

### MYSQL\_SERVICE\_PROGRESS\_REPORT\_INCLUDED

```cpp
#define MYSQL_SERVICE_PROGRESS_REPORT_INCLUDED
```

Defined in service\_progress\_report.h:80

***

### ENCRYPTION\_SCHEME\_KEY\_INVALID

```cpp
#define ENCRYPTION_SCHEME_KEY_INVALID -1
```

Defined in service\_encryption\_scheme.h:74

***

### ENCRYPTION\_SCHEME\_BLOCK\_LENGTH

```cpp
#define ENCRYPTION_SCHEME_BLOCK_LENGTH 16
```

Defined in service\_encryption\_scheme.h:75

***

### MYSQL\_SERVICE\_ENCRYPTION\_SCHEME\_INCLUDED

```cpp
#define MYSQL_SERVICE_ENCRYPTION_SCHEME_INCLUDED
```

Defined in service\_encryption\_scheme.h:132

***

### MYSQL\_PLUGIN\_PASSWORD\_VALIDATION\_INCLUDED

```cpp
#define MYSQL_PLUGIN_PASSWORD_VALIDATION_INCLUDED
```

Defined in plugin\_password\_validation.h:25

***

### MariaDB\_PASSWORD\_VALIDATION\_INTERFACE\_VERSION

```cpp
#define MariaDB_PASSWORD_VALIDATION_INTERFACE_VERSION 0x0101
```

Defined in plugin\_password\_validation.h:33

***

### MYSQL\_SERVICE\_THD\_STMT\_DA\_INCLUDED

```cpp
#define MYSQL_SERVICE_THD_STMT_DA_INCLUDED
```

Defined in service\_thd\_error\_context.h:92

## Enumerations

***

### PSI\_table\_io\_operation

```cpp
enum PSI_table_io_operation
```

Defined in psi/psi.h:241

IO operation performed on an instrumented table.

| Value                  | Description |
| ---------------------- | ----------- |
| `PSI_TABLE_FETCH_ROW`  | Row fetch.  |
| `PSI_TABLE_WRITE_ROW`  | Row write.  |
| `PSI_TABLE_UPDATE_ROW` | Row update. |
| `PSI_TABLE_DELETE_ROW` | Row delete. |

***

### enum\_mysql\_show\_type

```cpp
enum enum_mysql_show_type
```

Defined in plugin.h:187

| Value              | Description |
| ------------------ | ----------- |
| `SHOW_UNDEF`       |             |
| `SHOW_BOOL`        |             |
| `SHOW_UINT`        |             |
| `SHOW_ULONG`       |             |
| `SHOW_ULONGLONG`   |             |
| `SHOW_CHAR`        |             |
| `SHOW_CHAR_PTR`    |             |
| `SHOW_ARRAY`       |             |
| `SHOW_FUNC`        |             |
| `SHOW_DOUBLE`      |             |
| `SHOW_SINT`        |             |
| `SHOW_SLONG`       |             |
| `SHOW_SLONGLONG`   |             |
| `SHOW_SIMPLE_FUNC` |             |
| `SHOW_SIZE_T`      |             |
| `SHOW_always_last` |             |

***

### enum\_var\_type

```cpp
enum enum_var_type
```

Defined in plugin.h:201

| Value                      | Description |
| -------------------------- | ----------- |
| `SHOW_OPT_DEFAULT`         |             |
| `SHOW_OPT_SESSION`         |             |
| `SHOW_OPT_GLOBAL`          |             |
| `SHOW_OPT_SESSION_NO_LOCK` |             |

***

### json\_types

```cpp
enum json_types
```

Defined in service\_json.h:51

| Value          | Description |
| -------------- | ----------- |
| `JSV_BAD_JSON` |             |
| `JSV_NOTHING`  |             |
| `JSV_OBJECT`   |             |
| `JSV_ARRAY`    |             |
| `JSV_STRING`   |             |
| `JSV_NUMBER`   |             |
| `JSV_TRUE`     |             |
| `JSV_FALSE`    |             |
| `JSV_NULL`     |             |

***

### Wsrep\_service\_key\_type

```cpp
enum Wsrep_service_key_type
```

Defined in service\_wsrep.h:4

| Value                         | Description |
| ----------------------------- | ----------- |
| `WSREP_SERVICE_KEY_SHARED`    |             |
| `WSREP_SERVICE_KEY_REFERENCE` |             |
| `WSREP_SERVICE_KEY_UPDATE`    |             |
| `WSREP_SERVICE_KEY_EXCLUSIVE` |             |

***

### enum\_ftparser\_mode

```cpp
enum enum_ftparser_mode
```

Defined in plugin\_ftparser.h:32

| Value                              | Description |
| ---------------------------------- | ----------- |
| `MYSQL_FTPARSER_SIMPLE_MODE`       |             |
| `MYSQL_FTPARSER_WITH_STOPWORDS`    |             |
| `MYSQL_FTPARSER_FULL_BOOLEAN_INFO` |             |

***

### enum\_ft\_token\_type

```cpp
enum enum_ft_token_type
```

Defined in plugin\_ftparser.h:80

| Value                  | Description |
| ---------------------- | ----------- |
| `FT_TOKEN_EOF`         |             |
| `FT_TOKEN_WORD`        |             |
| `FT_TOKEN_LEFT_PAREN`  |             |
| `FT_TOKEN_RIGHT_PAREN` |             |
| `FT_TOKEN_STOPWORD`    |             |

***

### my\_aes\_mode

```cpp
enum my_aes_mode
```

Defined in service\_my\_crypt.h:50

| Value        | Description |
| ------------ | ----------- |
| `MY_AES_ECB` |             |
| `MY_AES_CBC` |             |

***

### my\_digest

```cpp
enum my_digest
```

Defined in service\_my\_crypt.h:60

| Value              | Description |
| ------------------ | ----------- |
| `MY_DIGEST_SHA1`   |             |
| `MY_DIGEST_SHA224` |             |
| `MY_DIGEST_SHA256` |             |
| `MY_DIGEST_SHA384` |             |
| `MY_DIGEST_SHA512` |             |

***

### \_thd\_wait\_type\_e

```cpp
enum _thd_wait_type_e
```

Defined in service\_thd\_wait.h:66

| Value                     | Description |
| ------------------------- | ----------- |
| `THD_WAIT_SLEEP`          |             |
| `THD_WAIT_DISKIO`         |             |
| `THD_WAIT_ROW_LOCK`       |             |
| `THD_WAIT_GLOBAL_LOCK`    |             |
| `THD_WAIT_META_DATA_LOCK` |             |
| `THD_WAIT_TABLE_LOCK`     |             |
| `THD_WAIT_USER_LOCK`      |             |
| `THD_WAIT_BINLOG`         |             |
| `THD_WAIT_GROUP_COMMIT`   |             |
| `THD_WAIT_SYNC`           |             |
| `THD_WAIT_NET`            |             |
| `THD_WAIT_LAST`           |             |

***

### thd\_kill\_levels

```cpp
enum thd_kill_levels
```

Defined in service\_kill\_statement.h:42

| Value               | Description                                       |
| ------------------- | ------------------------------------------------- |
| `THD_IS_NOT_KILLED` |                                                   |
| `THD_ABORT_SOFTLY`  | abort when possible, don't leave tables corrupted |
| `THD_ABORT_ASAP`    | abort asap                                        |

## Typedefs

***

### MDL\_key

```cpp
using MDL_key = struct MDL_key
```

Type: struct [`MDL_key`](#mdl_key)

Defined in psi/psi.h:70

***

### opaque\_mdl\_type

```cpp
using opaque_mdl_type = int
```

Defined in psi/psi.h:73

**See also**: enum\_mdl\_type.

***

### opaque\_mdl\_duration

```cpp
using opaque_mdl_duration = int
```

Defined in psi/psi.h:76

**See also**: enum\_mdl\_duration.

***

### opaque\_mdl\_status

```cpp
using opaque_mdl_status = int
```

Defined in psi/psi.h:79

**See also**: MDL\_wait::enum\_wait\_status.

***

### opaque\_vio\_type

```cpp
using opaque_vio_type = int
```

Defined in psi/psi.h:82

**See also**: enum\_vio\_type.

***

### THD

```cpp
using THD = struct opaque_THD
```

Type: struct [`opaque_THD`](#opaque_thd)

Defined in psi/psi.h:99

***

### PSI\_mutex

```cpp
using PSI_mutex = struct PSI_mutex
```

Type: struct [`PSI_mutex`](#psi_mutex)

Defined in psi/psi.h:115

***

### PSI\_rwlock

```cpp
using PSI_rwlock = struct PSI_rwlock
```

Type: struct [`PSI_rwlock`](#psi_rwlock)

Defined in psi/psi.h:122

***

### PSI\_cond

```cpp
using PSI_cond = struct PSI_cond
```

Type: struct [`PSI_cond`](#psi_cond)

Defined in psi/psi.h:129

***

### PSI\_table\_share

```cpp
using PSI_table_share = struct PSI_table_share
```

Type: struct [`PSI_table_share`](#psi_table_share)

Defined in psi/psi.h:136

***

### PSI\_table

```cpp
using PSI_table = struct PSI_table
```

Type: struct [`PSI_table`](#psi_table)

Defined in psi/psi.h:143

***

### PSI\_thread

```cpp
using PSI_thread = struct PSI_thread
```

Type: struct [`PSI_thread`](#psi_thread)

Defined in psi/psi.h:150

***

### PSI\_file

```cpp
using PSI_file = struct PSI_file
```

Type: struct [`PSI_file`](#psi_file)

Defined in psi/psi.h:157

***

### PSI\_socket

```cpp
using PSI_socket = struct PSI_socket
```

Type: struct [`PSI_socket`](#psi_socket)

Defined in psi/psi.h:164

***

### PSI\_prepared\_stmt

```cpp
using PSI_prepared_stmt = struct PSI_prepared_stmt
```

Type: struct [`PSI_prepared_stmt`](#psi_prepared_stmt)

Defined in psi/psi.h:171

***

### PSI\_table\_locker

```cpp
using PSI_table_locker = struct PSI_table_locker
```

Type: struct [`PSI_table_locker`](#psi_table_locker)

Defined in psi/psi.h:178

***

### PSI\_statement\_locker

```cpp
using PSI_statement_locker = struct PSI_statement_locker
```

Type: struct [`PSI_statement_locker`](#psi_statement_locker)

Defined in psi/psi.h:185

***

### PSI\_transaction\_locker

```cpp
using PSI_transaction_locker = struct PSI_transaction_locker
```

Type: struct [`PSI_transaction_locker`](#psi_transaction_locker)

Defined in psi/psi.h:192

***

### PSI\_idle\_locker

```cpp
using PSI_idle_locker = struct PSI_idle_locker
```

Type: struct [`PSI_idle_locker`](#psi_idle_locker)

Defined in psi/psi.h:199

***

### PSI\_digest\_locker

```cpp
using PSI_digest_locker = struct PSI_digest_locker
```

Type: struct [`PSI_digest_locker`](#psi_digest_locker)

Defined in psi/psi.h:206

***

### PSI\_sp\_share

```cpp
using PSI_sp_share = struct PSI_sp_share
```

Type: struct [`PSI_sp_share`](#psi_sp_share)

Defined in psi/psi.h:213

***

### PSI\_sp\_locker

```cpp
using PSI_sp_locker = struct PSI_sp_locker
```

Type: struct [`PSI_sp_locker`](#psi_sp_locker)

Defined in psi/psi.h:220

***

### PSI\_metadata\_lock

```cpp
using PSI_metadata_lock = struct PSI_metadata_lock
```

Type: struct [`PSI_metadata_lock`](#psi_metadata_lock)

Defined in psi/psi.h:227

***

### PSI\_stage\_progress

```cpp
using PSI_stage_progress = struct PSI_stage_progress
```

Type: struct [`PSI_stage_progress`](/docs/server/reference/plugins/api-plugin/instrumentation_interface.md#psi_stage_progress-1)

Defined in psi/psi.h:238

***

### PSI\_table\_io\_operation

```cpp
using PSI_table_io_operation = enum PSI_table_io_operation
```

Type: enum [`PSI_table_io_operation`](#psi_table_io_operation)

Defined in psi/psi.h:252

***

### PSI\_table\_locker\_state

```cpp
using PSI_table_locker_state = struct PSI_table_locker_state
```

Type: struct [`PSI_table_locker_state`](/docs/server/reference/plugins/api-plugin/instrumentation_interface.md#psi_table_locker_state-1)

Defined in psi/psi.h:290

***

### PSI\_bootstrap

```cpp
using PSI_bootstrap = struct PSI_bootstrap
```

Type: struct [`PSI_bootstrap`](/docs/server/reference/plugins/api-plugin/instrumentation_interface.md#psi_bootstrap-1)

Defined in psi/psi.h:310

***

### PSI\_mutex\_key

```cpp
using PSI_mutex_key = unsigned int
```

Defined in psi/psi.h:792

Instrumented mutex key. To instrument a mutex, a mutex key must be obtained using `register_mutex`. Using a zero key always disable the instrumentation.

***

### PSI\_rwlock\_key

```cpp
using PSI_rwlock_key = unsigned int
```

Defined in psi/psi.h:800

Instrumented rwlock key. To instrument a rwlock, a rwlock key must be obtained using `register_rwlock`. Using a zero key always disable the instrumentation.

***

### PSI\_cond\_key

```cpp
using PSI_cond_key = unsigned int
```

Defined in psi/psi.h:808

Instrumented cond key. To instrument a condition, a condition key must be obtained using `register_cond`. Using a zero key always disable the instrumentation.

***

### PSI\_thread\_key

```cpp
using PSI_thread_key = unsigned int
```

Defined in psi/psi.h:816

Instrumented thread key. To instrument a thread, a thread key must be obtained using `register_thread`. Using a zero key always disable the instrumentation.

***

### PSI\_file\_key

```cpp
using PSI_file_key = unsigned int
```

Defined in psi/psi.h:823

Instrumented file key. To instrument a file, a file key must be obtained using `register_file`. Using a zero key always disable the instrumentation.

***

### PSI\_stage\_key

```cpp
using PSI_stage_key = unsigned int
```

Defined in psi/psi.h:830

Instrumented stage key. To instrument a stage, a stage key must be obtained using `register_stage`. Using a zero key always disable the instrumentation.

***

### PSI\_statement\_key

```cpp
using PSI_statement_key = unsigned int
```

Defined in psi/psi.h:837

Instrumented statement key. To instrument a statement, a statement key must be obtained using `register_statement`. Using a zero key always disable the instrumentation.

***

### PSI\_socket\_key

```cpp
using PSI_socket_key = unsigned int
```

Defined in psi/psi.h:844

Instrumented socket key. To instrument a socket, a socket key must be obtained using `register_socket`. Using a zero key always disable the instrumentation.

***

### PSI\_mutex\_info\_v1

```cpp
using PSI_mutex_info_v1 = struct PSI_mutex_info_v1
```

Type: struct [`PSI_mutex_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_mutex_info_v1-1)

Defined in psi/psi.h:875

***

### PSI\_rwlock\_info\_v1

```cpp
using PSI_rwlock_info_v1 = struct PSI_rwlock_info_v1
```

Type: struct [`PSI_rwlock_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_rwlock_info_v1-1)

Defined in psi/psi.h:898

***

### PSI\_cond\_info\_v1

```cpp
using PSI_cond_info_v1 = struct PSI_cond_info_v1
```

Type: struct [`PSI_cond_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_cond_info_v1-1)

Defined in psi/psi.h:921

***

### PSI\_thread\_info\_v1

```cpp
using PSI_thread_info_v1 = struct PSI_thread_info_v1
```

Type: struct [`PSI_thread_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_thread_info_v1-1)

Defined in psi/psi.h:944

***

### PSI\_file\_info\_v1

```cpp
using PSI_file_info_v1 = struct PSI_file_info_v1
```

Type: struct [`PSI_file_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_file_info_v1-1)

Defined in psi/psi.h:967

***

### PSI\_stage\_info\_v1

```cpp
using PSI_stage_info_v1 = struct PSI_stage_info_v1
```

Type: struct [`PSI_stage_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_stage_info_v1-1)

Defined in psi/psi.h:983

***

### PSI\_statement\_info\_v1

```cpp
using PSI_statement_info_v1 = struct PSI_statement_info_v1
```

Type: struct [`PSI_statement_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_statement_info_v1-1)

Defined in psi/psi.h:999

***

### PSI\_socket\_info\_v1

```cpp
using PSI_socket_info_v1 = struct PSI_socket_info_v1
```

Type: struct [`PSI_socket_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_socket_info_v1-1)

Defined in psi/psi.h:1022

***

### PSI\_idle\_locker\_state\_v1

```cpp
using PSI_idle_locker_state_v1 = struct PSI_idle_locker_state_v1
```

Type: struct [`PSI_idle_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_idle_locker_state_v1-1)

Defined in psi/psi.h:1046

***

### PSI\_mutex\_locker\_state\_v1

```cpp
using PSI_mutex_locker_state_v1 = struct PSI_mutex_locker_state_v1
```

Type: struct [`PSI_mutex_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_mutex_locker_state_v1-1)

Defined in psi/psi.h:1074

***

### PSI\_rwlock\_locker\_state\_v1

```cpp
using PSI_rwlock_locker_state_v1 = struct PSI_rwlock_locker_state_v1
```

Type: struct [`PSI_rwlock_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_rwlock_locker_state_v1-1)

Defined in psi/psi.h:1103

***

### PSI\_cond\_locker\_state\_v1

```cpp
using PSI_cond_locker_state_v1 = struct PSI_cond_locker_state_v1
```

Type: struct [`PSI_cond_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_cond_locker_state_v1-1)

Defined in psi/psi.h:1133

***

### PSI\_file\_locker\_state\_v1

```cpp
using PSI_file_locker_state_v1 = struct PSI_file_locker_state_v1
```

Type: struct [`PSI_file_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_file_locker_state_v1-1)

Defined in psi/psi.h:1169

***

### PSI\_metadata\_locker\_state\_v1

```cpp
using PSI_metadata_locker_state_v1 = struct PSI_metadata_locker_state_v1
```

Type: struct [`PSI_metadata_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_metadata_locker_state_v1-1)

Defined in psi/psi.h:1195

***

### PSI\_statement\_locker\_state\_v1

```cpp
using PSI_statement_locker_state_v1 = struct PSI_statement_locker_state_v1
```

Type: struct [`PSI_statement_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_statement_locker_state_v1-1)

Defined in psi/psi.h:1271

***

### PSI\_transaction\_locker\_state\_v1

```cpp
using PSI_transaction_locker_state_v1 = struct PSI_transaction_locker_state_v1
```

Type: struct [`PSI_transaction_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_transaction_locker_state_v1-1)

Defined in psi/psi.h:1311

***

### PSI\_socket\_locker\_state\_v1

```cpp
using PSI_socket_locker_state_v1 = struct PSI_socket_locker_state_v1
```

Type: struct [`PSI_socket_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_socket_locker_state_v1-1)

Defined in psi/psi.h:1345

***

### PSI\_sp\_locker\_state\_v1

```cpp
using PSI_sp_locker_state_v1 = struct PSI_sp_locker_state_v1
```

Type: struct [`PSI_sp_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_sp_locker_state_v1-1)

Defined in psi/psi.h:1360

***

### register\_mutex\_v1\_t

```cpp
using register_mutex_v1_t = void(*
```

Defined in psi/psi.h:1370

Mutex registration API.

#### Parameters

| Parameter  | Type | Description                               |
| ---------- | ---- | ----------------------------------------- |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of mutex info to register        |
| `count`    |      | the size of the info array                |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of mutex info to register        |
| `count`    |      | the size of the info array                |

***

### register\_rwlock\_v1\_t

```cpp
using register_rwlock_v1_t = void(*
```

Defined in psi/psi.h:1379

Rwlock registration API.

#### Parameters

| Parameter  | Type | Description                               |
| ---------- | ---- | ----------------------------------------- |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of rwlock info to register       |
| `count`    |      | the size of the info array                |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of rwlock info to register       |
| `count`    |      | the size of the info array                |

***

### register\_cond\_v1\_t

```cpp
using register_cond_v1_t = void(*
```

Defined in psi/psi.h:1388

Cond registration API.

#### Parameters

| Parameter  | Type | Description                               |
| ---------- | ---- | ----------------------------------------- |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of cond info to register         |
| `count`    |      | the size of the info array                |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of cond info to register         |
| `count`    |      | the size of the info array                |

***

### register\_thread\_v1\_t

```cpp
using register_thread_v1_t = void(*
```

Defined in psi/psi.h:1397

Thread registration API.

#### Parameters

| Parameter  | Type | Description                               |
| ---------- | ---- | ----------------------------------------- |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of thread info to register       |
| `count`    |      | the size of the info array                |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of thread info to register       |
| `count`    |      | the size of the info array                |

***

### register\_file\_v1\_t

```cpp
using register_file_v1_t = void(*
```

Defined in psi/psi.h:1406

File registration API.

#### Parameters

| Parameter  | Type | Description                               |
| ---------- | ---- | ----------------------------------------- |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of file info to register         |
| `count`    |      | the size of the info array                |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of file info to register         |
| `count`    |      | the size of the info array                |

***

### register\_stage\_v1\_t

```cpp
using register_stage_v1_t = void(*
```

Defined in psi/psi.h:1415

Stage registration API.

#### Parameters

| Parameter  | Type | Description                        |
| ---------- | ---- | ---------------------------------- |
| `category` |      | a category name                    |
| `info`     |      | an array of stage info to register |
| `count`    |      | the size of the info array         |
| `category` |      | a category name                    |
| `info`     |      | an array of stage info to register |
| `count`    |      | the size of the info array         |

***

### register\_statement\_v1\_t

```cpp
using register_statement_v1_t = void(*
```

Defined in psi/psi.h:1424

Statement registration API.

#### Parameters

| Parameter  | Type | Description                        |
| ---------- | ---- | ---------------------------------- |
| `category` |      | a category name                    |
| `info`     |      | an array of stage info to register |
| `count`    |      | the size of the info array         |
| `category` |      | a category name                    |
| `info`     |      | an array of stage info to register |
| `count`    |      | the size of the info array         |

***

### register\_socket\_v1\_t

```cpp
using register_socket_v1_t = void(*
```

Defined in psi/psi.h:1433

Socket registration API.

#### Parameters

| Parameter  | Type | Description                               |
| ---------- | ---- | ----------------------------------------- |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of socket info to register       |
| `count`    |      | the size of the info array                |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of socket info to register       |
| `count`    |      | the size of the info array                |

***

### init\_mutex\_v1\_t

```cpp
using init_mutex_v1_t = struct PSI_mutex *(*
```

Defined in psi/psi.h:1433

Mutex instrumentation initialisation API.

#### Returns

an instrumented mutex

#### Parameters

| Parameter  | Type | Description                     |
| ---------- | ---- | ------------------------------- |
| `key`      |      | the registered mutex key        |
| `identity` |      | the address of the mutex itself |
| `key`      |      | the registered mutex key        |
| `identity` |      | the address of the mutex itself |

***

### destroy\_mutex\_v1\_t

```cpp
using destroy_mutex_v1_t = void(*
```

Defined in psi/psi.h:1449

Mutex instrumentation destruction API.

#### Parameters

| Parameter | Type | Description          |
| --------- | ---- | -------------------- |
| `mutex`   |      | the mutex to destroy |
| `mutex`   |      | the mutex to destroy |

***

### init\_rwlock\_v1\_t

```cpp
using init_rwlock_v1_t = struct PSI_rwlock *(*
```

Defined in psi/psi.h:1449

Rwlock instrumentation initialisation API.

#### Returns

an instrumented rwlock

#### Parameters

| Parameter  | Type | Description                      |
| ---------- | ---- | -------------------------------- |
| `key`      |      | the registered rwlock key        |
| `identity` |      | the address of the rwlock itself |
| `key`      |      | the registered rwlock key        |
| `identity` |      | the address of the rwlock itself |

***

### destroy\_rwlock\_v1\_t

```cpp
using destroy_rwlock_v1_t = void(*
```

Defined in psi/psi.h:1464

Rwlock instrumentation destruction API.

#### Parameters

| Parameter | Type | Description           |
| --------- | ---- | --------------------- |
| `rwlock`  |      | the rwlock to destroy |
| `rwlock`  |      | the rwlock to destroy |

***

### init\_cond\_v1\_t

```cpp
using init_cond_v1_t = struct PSI_cond *(*
```

Defined in psi/psi.h:1464

Cond instrumentation initialisation API.

#### Returns

an instrumented cond

#### Parameters

| Parameter  | Type | Description                      |
| ---------- | ---- | -------------------------------- |
| `key`      |      | the registered key               |
| `identity` |      | the address of the rwlock itself |
| `key`      |      | the registered key               |
| `identity` |      | the address of the rwlock itself |

***

### destroy\_cond\_v1\_t

```cpp
using destroy_cond_v1_t = void(*
```

Defined in psi/psi.h:1479

Cond instrumentation destruction API.

#### Parameters

| Parameter | Type | Description          |
| --------- | ---- | -------------------- |
| `cond`    |      | the rcond to destroy |
| `cond`    |      | the rcond to destroy |

***

### init\_socket\_v1\_t

```cpp
using init_socket_v1_t = struct PSI_socket *(*
```

Defined in psi/psi.h:1479

Socket instrumentation initialisation API.

#### Returns

an instrumented socket

#### Parameters

| Parameter  | Type | Description                 |
| ---------- | ---- | --------------------------- |
| `key`      |      | the registered socket key   |
| `fd`       |      | the socket descriptor       |
| `addr`     |      | the socket ip address       |
| `addr_len` |      | length of socket ip address |
| `key`      |      | the registered socket key   |
| `fd`       |      | the socket descriptor       |
| `addr`     |      | the socket ip address       |
| `addr_len` |      | length of socket ip address |

***

### destroy\_socket\_v1\_t

```cpp
using destroy_socket_v1_t = void(*
```

Defined in psi/psi.h:1497

socket instrumentation destruction API.

#### Parameters

| Parameter | Type | Description           |
| --------- | ---- | --------------------- |
| `socket`  |      | the socket to destroy |
| `socket`  |      | the socket to destroy |

***

### get\_table\_share\_v1\_t

```cpp
using get_table_share_v1_t = struct PSI_table_share *(*
```

Defined in psi/psi.h:1497

Acquire a table share instrumentation.

#### Returns

a table share instrumentation, or NULL

#### Parameters

| Parameter   | Type | Description               |
| ----------- | ---- | ------------------------- |
| `temporary` |      | True for temporary tables |
| `share`     |      | The SQL layer table share |
| `temporary` |      | True for temporary tables |
| `share`     |      | The SQL layer table share |

***

### release\_table\_share\_v1\_t

```cpp
using release_table_share_v1_t = void(*
```

Defined in psi/psi.h:1512

Release a table share.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `share`   |      | the table share to release |
| `share`   |      | the table share to release |

***

### drop\_table\_share\_v1\_t

```cpp
using drop_table_share_v1_t = void(*
```

Defined in psi/psi.h:1522

Drop a table share.

#### Parameters

| Parameter            | Type | Description                  |
| -------------------- | ---- | ---------------------------- |
| `temporary`          |      | True for temporary tables    |
| `schema_name`        |      | the table schema name        |
| `schema_name_length` |      | the table schema name length |
| `table_name`         |      | the table name               |
| `table_name_length`  |      | the table name length        |
| `temporary`          |      | True for temporary tables    |
| `schema_name`        |      | the table schema name        |
| `schema_name_length` |      | the table schema name length |
| `table_name`         |      | the table name               |
| `table_name_length`  |      | the table name length        |

***

### open\_table\_v1\_t

```cpp
using open_table_v1_t = struct PSI_table *(*
```

Defined in psi/psi.h:1522

Open an instrumentation table handle.

#### Returns

a table handle, or NULL

#### Parameters

| Parameter  | Type | Description           |
| ---------- | ---- | --------------------- |
| `share`    |      | the table to open     |
| `identity` |      | table handle identity |
| `share`    |      | the table to open     |
| `identity` |      | table handle identity |

***

### unbind\_table\_v1\_t

```cpp
using unbind_table_v1_t = void(*
```

Defined in psi/psi.h:1540

Unbind a table handle from the current thread. This operation happens when an opened table is added to the open table cache.

#### Parameters

| Parameter | Type | Description         |
| --------- | ---- | ------------------- |
| `table`   |      | the table to unbind |
| `table`   |      | the table to unbind |

***

### rebind\_table\_v1\_t

```cpp
using rebind_table_v1_t = PSI_table *(*
```

Defined in psi/psi.h:1548

Rebind a table handle to the current thread. This operation happens when a table from the open table cache is reused for a thread.

***

### close\_table\_v1\_t

```cpp
using close_table_v1_t = void(*
```

Defined in psi/psi.h:1555

Close an instrumentation table handle. Note that the table handle is invalid after this call.

***

### create\_file\_v1\_t

```cpp
using create_file_v1_t = void(*
```

Defined in psi/psi.h:1566

Create a file instrumentation for a created file. This method does not create the file itself, but is used to notify the instrumentation interface that a file was just created.

#### Parameters

| Parameter | Type | Description                                |
| --------- | ---- | ------------------------------------------ |
| `key`     |      | the file instrumentation key for this file |
| `name`    |      | the file name                              |
| `file`    |      | the file handle                            |
| `key`     |      | the file instrumentation key for this file |
| `name`    |      | the file name                              |
| `file`    |      | the file handle                            |

***

### spawn\_thread\_v1\_t

```cpp
using spawn_thread_v1_t = int(*
```

Defined in psi/psi.h:1578

Spawn a thread. This method creates a new thread, with instrumentation.

#### Parameters

| Parameter       | Type | Description                             |
| --------------- | ---- | --------------------------------------- |
| `key`           |      | the instrumentation key for this thread |
| `thread`        |      | the resulting thread                    |
| `attr`          |      | the thread attributes                   |
| `start_routine` |      | the thread start routine                |
| `arg`           |      | the thread start routine argument       |
| `key`           |      | the instrumentation key for this thread |
| `thread`        |      | the resulting thread                    |
| `attr`          |      | the thread attributes                   |
| `start_routine` |      | the thread start routine                |
| `arg`           |      | the thread start routine argument       |

***

### new\_thread\_v1\_t

```cpp
using new_thread_v1_t = struct PSI_thread *(*
```

Defined in psi/psi.h:1578

Create instrumentation for a thread.

#### Returns

an instrumented thread

#### Parameters

| Parameter   | Type | Description                      |
| ----------- | ---- | -------------------------------- |
| `key`       |      | the registered key               |
| `identity`  |      | an address typical of the thread |
| `thread_id` |      | the id of the thread             |
| `key`       |      | the registered key               |
| `identity`  |      | an address typical of the thread |
| `thread_id` |      | the id of the thread             |

***

### set\_thread\_THD\_v1\_t

```cpp
using set_thread_THD_v1_t = void(*
```

Defined in psi/psi.h:1598

Assign a THD to an instrumented thread.

#### Parameters

| Parameter | Type | Description                 |
| --------- | ---- | --------------------------- |
| `thread`  |      | the instrumented thread     |
| `thd`     |      | the sql layer THD to assign |
| `thread`  |      | the instrumented thread     |
| `thd`     |      | the sql layer THD to assign |

***

### set\_thread\_id\_v1\_t

```cpp
using set_thread_id_v1_t = void(*
```

Defined in psi/psi.h:1606

Assign an id to an instrumented thread.

#### Parameters

| Parameter | Type | Description             |
| --------- | ---- | ----------------------- |
| `thread`  |      | the instrumented thread |
| `id`      |      | the id to assign        |
| `thread`  |      | the instrumented thread |
| `id`      |      | the id to assign        |

***

### set\_thread\_os\_id\_v1\_t

```cpp
using set_thread_os_id_v1_t = void(*
```

Defined in psi/psi.h:1614

Assign the current operating system thread id to an instrumented thread. The operating system task id is obtained from `gettid()`

#### Parameters

| Parameter | Type | Description             |
| --------- | ---- | ----------------------- |
| `thread`  |      | the instrumented thread |
| `thread`  |      | the instrumented thread |

***

### get\_thread\_v1\_t

```cpp
using get_thread_v1_t = struct PSI_thread *(*
```

Defined in psi/psi.h:1614

Get the instrumentation for the running thread. For this function to return a result, the thread instrumentation must have been attached to the running thread using `set_thread()`

#### Returns

the instrumentation for the running thread

***

### get\_thread\_class\_name\_v1\_t

```cpp
using get_thread_class_name_v1_t = const char *(*
```

Defined in psi/psi.h:1629

Get name of the thread, according to the thread class. The name is returns without the thread/subsystem prefix.

***

### set\_thread\_user\_v1\_t

```cpp
using set_thread_user_v1_t = void(*
```

Defined in psi/psi.h:1636

Assign a user name to the instrumented thread.

#### Parameters

| Parameter  | Type | Description          |
| ---------- | ---- | -------------------- |
| `user`     |      | the user name        |
| `user_len` |      | the user name length |
| `user`     |      | the user name        |
| `user_len` |      | the user name length |

***

### set\_thread\_account\_v1\_t

```cpp
using set_thread_account_v1_t = void(*
```

Defined in psi/psi.h:1645

Assign a user name and host name to the instrumented thread.

#### Parameters

| Parameter  | Type | Description          |
| ---------- | ---- | -------------------- |
| `user`     |      | the user name        |
| `user_len` |      | the user name length |
| `host`     |      | the host name        |
| `host_len` |      | the host name length |
| `user`     |      | the user name        |
| `user_len` |      | the user name length |
| `host`     |      | the host name        |
| `host_len` |      | the host name length |

***

### set\_thread\_db\_v1\_t

```cpp
using set_thread_db_v1_t = void(*
```

Defined in psi/psi.h:1653

Assign a current database to the instrumented thread.

#### Parameters

| Parameter | Type | Description              |
| --------- | ---- | ------------------------ |
| `db`      |      | the database name        |
| `db_len`  |      | the database name length |
| `db`      |      | the database name        |
| `db_len`  |      | the database name length |

***

### set\_thread\_command\_v1\_t

```cpp
using set_thread_command_v1_t = void(*
```

Defined in psi/psi.h:1659

Assign a current command to the instrumented thread.

#### Parameters

| Parameter | Type | Description         |
| --------- | ---- | ------------------- |
| `command` |      | the current command |
| `command` |      | the current command |

***

### set\_connection\_type\_v1\_t

```cpp
using set_connection_type_v1_t = void(*
```

Defined in psi/psi.h:1665

Assign a connection type to the instrumented thread.

#### Parameters

| Parameter   | Type | Description         |
| ----------- | ---- | ------------------- |
| `conn_type` |      | the connection type |
| `conn_type` |      | the connection type |

***

### set\_thread\_start\_time\_v1\_t

```cpp
using set_thread_start_time_v1_t = void(*
```

Defined in psi/psi.h:1672

Assign a start time to the instrumented thread.

#### Parameters

| Parameter    | Type | Description           |
| ------------ | ---- | --------------------- |
| `start_time` |      | the thread start time |
| `start_time` |      | the thread start time |

***

### set\_thread\_state\_v1\_t

```cpp
using set_thread_state_v1_t = void(*
```

Defined in psi/psi.h:1678

Assign a state to the instrumented thread.

#### Parameters

| Parameter | Type | Description      |
| --------- | ---- | ---------------- |
| `state`   |      | the thread state |
| `state`   |      | the thread state |

***

### set\_thread\_info\_v1\_t

```cpp
using set_thread_info_v1_t = void(*
```

Defined in psi/psi.h:1685

Assign a process info to the instrumented thread.

#### Parameters

| Parameter  | Type | Description                    |
| ---------- | ---- | ------------------------------ |
| `info`     |      | the process into string        |
| `info_len` |      | the process into string length |
| `info`     |      | the process into string        |
| `info_len` |      | the process into string length |

***

### set\_thread\_v1\_t

```cpp
using set_thread_v1_t = void(*
```

Defined in psi/psi.h:1696

Attach a thread instrumentation to the running thread. In case of thread pools, this method should be called when a worker thread picks a work item and runs it. Also, this method should be called if the instrumented code does not keep the pointer returned by `new_thread()` and relies on `get_thread()` instead.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `thread`  |      | the thread instrumentation |
| `thread`  |      | the thread instrumentation |

***

### set\_thread\_peer\_port\_v1\_t

```cpp
using set_thread_peer_port_v1_t = void(*
```

Defined in psi/psi.h:1704

Assign the remote (peer) port to the instrumented thread.

#### Parameters

| Parameter | Type | Description                           |
| --------- | ---- | ------------------------------------- |
| `thread`  |      | pointer to the thread instrumentation |
| `port`    |      | the remote port                       |
| `thread`  |      | pointer to the thread instrumentation |
| `port`    |      | the remote port                       |

***

### delete\_current\_thread\_v1\_t

```cpp
using delete_current_thread_v1_t = void(*
```

Defined in psi/psi.h:1708

Delete the current thread instrumentation.

***

### delete\_thread\_v1\_t

```cpp
using delete_thread_v1_t = void(*
```

Defined in psi/psi.h:1711

Delete a thread instrumentation.

***

### get\_thread\_file\_name\_locker\_v1\_t

```cpp
using get_thread_file_name_locker_v1_t = struct PSI_file_locker *(*
```

Defined in psi/psi.h:1711

Get a file instrumentation locker, for opening or creating a file.

#### Returns

a file locker, or NULL

#### Parameters

| Parameter  | Type | Description                            |
| ---------- | ---- | -------------------------------------- |
| `state`    |      | data storage for the locker            |
| `key`      |      | the file instrumentation key           |
| `op`       |      | the operation to perform               |
| `name`     |      | the file name                          |
| `identity` |      | a pointer representative of this file. |
| `state`    |      | data storage for the locker            |
| `key`      |      | the file instrumentation key           |
| `op`       |      | the operation to perform               |
| `name`     |      | the file name                          |
| `identity` |      | a pointer representative of this file. |

***

### get\_thread\_file\_stream\_locker\_v1\_t

```cpp
using get_thread_file_stream_locker_v1_t = struct PSI_file_locker *(*
```

Defined in psi/psi.h:1711

Get a file stream instrumentation locker.

#### Returns

a file locker, or NULL

#### Parameters

| Parameter | Type | Description                 |
| --------- | ---- | --------------------------- |
| `state`   |      | data storage for the locker |
| `file`    |      | the file stream to access   |
| `op`      |      | the operation to perform    |
| `state`   |      | data storage for the locker |
| `file`    |      | the file stream to access   |
| `op`      |      | the operation to perform    |

***

### get\_thread\_file\_descriptor\_locker\_v1\_t

```cpp
using get_thread_file_descriptor_locker_v1_t = struct PSI_file_locker *(*
```

Defined in psi/psi.h:1711

Get a file instrumentation locker.

#### Returns

a file locker, or NULL

#### Parameters

| Parameter | Type | Description                   |
| --------- | ---- | ----------------------------- |
| `state`   |      | data storage for the locker   |
| `file`    |      | the file descriptor to access |
| `op`      |      | the operation to perform      |
| `state`   |      | data storage for the locker   |
| `file`    |      | the file descriptor to access |
| `op`      |      | the operation to perform      |

***

### unlock\_mutex\_v1\_t

```cpp
using unlock_mutex_v1_t = void(*
```

Defined in psi/psi.h:1753

Record a mutex instrumentation unlock event.

#### Parameters

| Parameter | Type | Description               |
| --------- | ---- | ------------------------- |
| `mutex`   |      | the mutex instrumentation |
| `mutex`   |      | the mutex instrumentation |

***

### unlock\_rwlock\_v1\_t

```cpp
using unlock_rwlock_v1_t = void(*
```

Defined in psi/psi.h:1760

Record a rwlock instrumentation unlock event.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `rwlock`  |      | the rwlock instrumentation |
| `rwlock`  |      | the rwlock instrumentation |

***

### signal\_cond\_v1\_t

```cpp
using signal_cond_v1_t = void(*
```

Defined in psi/psi.h:1767

Record a condition instrumentation signal event.

#### Parameters

| Parameter | Type | Description              |
| --------- | ---- | ------------------------ |
| `cond`    |      | the cond instrumentation |
| `cond`    |      | the cond instrumentation |

***

### broadcast\_cond\_v1\_t

```cpp
using broadcast_cond_v1_t = void(*
```

Defined in psi/psi.h:1774

Record a condition instrumentation broadcast event.

#### Parameters

| Parameter | Type | Description              |
| --------- | ---- | ------------------------ |
| `cond`    |      | the cond instrumentation |
| `cond`    |      | the cond instrumentation |

***

### start\_idle\_wait\_v1\_t

```cpp
using start_idle_wait_v1_t = struct PSI_idle_locker *(*
```

Defined in psi/psi.h:1774

Record an idle instrumentation wait start event.

#### Returns

an idle locker, or NULL

#### Parameters

| Parameter  | Type | Description                 |
| ---------- | ---- | --------------------------- |
| `state`    |      | data storage for the locker |
| `src_file` |      | the source file name        |
| `src_line` |      | the source line number      |
| `state`    |      | data storage for the locker |
| `src_file` |      | the source file name        |
| `src_line` |      | the source line number      |

***

### end\_idle\_wait\_v1\_t

```cpp
using end_idle_wait_v1_t = void(*
```

Defined in psi/psi.h:1791

Record an idle instrumentation wait end event.

#### Parameters

| Parameter | Type | Description                            |
| --------- | ---- | -------------------------------------- |
| `locker`  |      | a thread locker for the running thread |
| `locker`  |      | a thread locker for the running thread |

***

### start\_mutex\_wait\_v1\_t

```cpp
using start_mutex_wait_v1_t = struct PSI_mutex_locker *(*
```

Defined in psi/psi.h:1791

Record a mutex instrumentation wait start event.

#### Returns

a mutex locker, or NULL

#### Parameters

| Parameter  | Type | Description                    |
| ---------- | ---- | ------------------------------ |
| `state`    |      | data storage for the locker    |
| `mutex`    |      | the instrumented mutex to lock |
| `op`       |      | the operation to perform       |
| `src_file` |      | the source file name           |
| `src_line` |      | the source line number         |
| `state`    |      | data storage for the locker    |
| `mutex`    |      | the instrumented mutex to lock |
| `op`       |      | the operation to perform       |
| `src_file` |      | the source file name           |
| `src_line` |      | the source line number         |

***

### end\_mutex\_wait\_v1\_t

```cpp
using end_mutex_wait_v1_t = void(*
```

Defined in psi/psi.h:1814

Record a mutex instrumentation wait end event.

#### Parameters

| Parameter | Type | Description                            |
| --------- | ---- | -------------------------------------- |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |

***

### start\_rwlock\_rdwait\_v1\_t

```cpp
using start_rwlock_rdwait_v1_t = struct PSI_rwlock_locker *(*
```

Defined in psi/psi.h:1814

Record a rwlock instrumentation read wait start event.

***

### end\_rwlock\_rdwait\_v1\_t

```cpp
using end_rwlock_rdwait_v1_t = void(*
```

Defined in psi/psi.h:1831

Record a rwlock instrumentation read wait end event.

#### Parameters

| Parameter | Type | Description                            |
| --------- | ---- | -------------------------------------- |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |

***

### start\_rwlock\_wrwait\_v1\_t

```cpp
using start_rwlock_wrwait_v1_t = struct PSI_rwlock_locker *(*
```

Defined in psi/psi.h:1831

Record a rwlock instrumentation write wait start event.

***

### end\_rwlock\_wrwait\_v1\_t

```cpp
using end_rwlock_wrwait_v1_t = void(*
```

Defined in psi/psi.h:1848

Record a rwlock instrumentation write wait end event.

#### Parameters

| Parameter | Type | Description                            |
| --------- | ---- | -------------------------------------- |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |

***

### start\_cond\_wait\_v1\_t

```cpp
using start_cond_wait_v1_t = struct PSI_cond_locker *(*
```

Defined in psi/psi.h:1848

Record a condition instrumentation wait start event.

***

### end\_cond\_wait\_v1\_t

```cpp
using end_cond_wait_v1_t = void(*
```

Defined in psi/psi.h:1866

Record a condition instrumentation wait end event.

#### Parameters

| Parameter | Type | Description                            |
| --------- | ---- | -------------------------------------- |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |
| `locker`  |      | a thread locker for the running thread |
| `rc`      |      | the wait operation return code         |

***

### start\_table\_io\_wait\_v1\_t

```cpp
using start_table_io_wait_v1_t = struct PSI_table_locker *(*
```

Defined in psi/psi.h:1866

Record a table instrumentation io wait start event.

#### Parameters

| Parameter  | Type | Description                                      |
| ---------- | ---- | ------------------------------------------------ |
| `state`    |      | data storage for the locker                      |
| `table`    |      | the instrumented table to lock                   |
| `op`       |      | the operation to perform                         |
| `index`    |      | the index number to lock, or 0 if not applicable |
| `src_file` |      | the source file name                             |
| `src_line` |      | the source line number                           |
| `state`    |      | data storage for the locker                      |
| `table`    |      | the instrumented table to lock                   |
| `op`       |      | the operation to perform                         |
| `index`    |      | the index number to lock, or 0 if not applicable |
| `src_file` |      | the source file name                             |
| `src_line` |      | the source line number                           |

***

### end\_table\_io\_wait\_v1\_t

```cpp
using end_table_io_wait_v1_t = void(*
```

Defined in psi/psi.h:1890

Record a table instrumentation io wait end event.

#### Parameters

| Parameter | Type | Description                           |
| --------- | ---- | ------------------------------------- |
| `locker`  |      | a table locker for the running thread |
| `numrows` |      | the number of rows involved in io     |
| `locker`  |      | a table locker for the running thread |
| `numrows` |      | the number of rows involved in io     |

***

### start\_table\_lock\_wait\_v1\_t

```cpp
using start_table_lock_wait_v1_t = struct PSI_table_locker *(*
```

Defined in psi/psi.h:1890

Record a table instrumentation lock wait start event.

***

### end\_table\_lock\_wait\_v1\_t

```cpp
using end_table_lock_wait_v1_t = void(*
```

Defined in psi/psi.h:1908

Record a table instrumentation lock wait end event.

#### Parameters

| Parameter | Type | Description                           |
| --------- | ---- | ------------------------------------- |
| `locker`  |      | a table locker for the running thread |
| `locker`  |      | a table locker for the running thread |

***

### unlock\_table\_v1\_t

```cpp
using unlock_table_v1_t = void(*
```

Defined in psi/psi.h:1910

***

### start\_file\_open\_wait\_v1\_t

```cpp
using start_file_open_wait_v1_t = void(*
```

Defined in psi/psi.h:1918

Start a file instrumentation open operation.

#### Parameters

| Parameter  | Type | Description            |
| ---------- | ---- | ---------------------- |
| `locker`   |      | the file locker        |
| `src_file` |      | the source file name   |
| `src_line` |      | the source line number |
| `locker`   |      | the file locker        |
| `src_file` |      | the source file name   |
| `src_line` |      | the source line number |

***

### end\_file\_open\_wait\_v1\_t

```cpp
using end_file_open_wait_v1_t = struct PSI_file *(*
```

Defined in psi/psi.h:1918

End a file instrumentation open operation, for file streams.

#### Returns

an instrumented file handle

#### Parameters

| Parameter | Type | Description                                                 |
| --------- | ---- | ----------------------------------------------------------- |
| `locker`  |      | the file locker.                                            |
| `result`  |      | the opened file (NULL indicates failure, non NULL success). |
| `locker`  |      | the file locker.                                            |
| `result`  |      | the opened file (NULL indicates failure, non NULL success). |

***

### end\_file\_open\_wait\_and\_bind\_to\_descriptor\_v1\_t

```cpp
using end_file_open_wait_and_bind_to_descriptor_v1_t = void(*
```

Defined in psi/psi.h:1935

End a file instrumentation open operation, for non stream files.

#### Parameters

| Parameter | Type | Description                                                   |
| --------- | ---- | ------------------------------------------------------------- |
| `locker`  |      | the file locker.                                              |
| `file`    |      | the file number assigned by open() or create() for this file. |
| `locker`  |      | the file locker.                                              |
| `file`    |      | the file number assigned by open() or create() for this file. |

***

### end\_temp\_file\_open\_wait\_and\_bind\_to\_descriptor\_v1\_t

```cpp
using end_temp_file_open_wait_and_bind_to_descriptor_v1_t = void(*
```

Defined in psi/psi.h:1944

End a file instrumentation open operation, for non stream temporary files.

#### Parameters

| Parameter  | Type | Description                                                   |
| ---------- | ---- | ------------------------------------------------------------- |
| `locker`   |      | the file locker.                                              |
| `file`     |      | the file number assigned by open() or create() for this file. |
| `filename` |      | the file name generated during temporary file creation.       |
| `locker`   |      | the file locker.                                              |
| `file`     |      | the file number assigned by open() or create() for this file. |
| `filename` |      | the file name generated during temporary file creation.       |

***

### start\_file\_wait\_v1\_t

```cpp
using start_file_wait_v1_t = void(*
```

Defined in psi/psi.h:1954

Record a file instrumentation start event.

#### Parameters

| Parameter  | Type | Description                                           |
| ---------- | ---- | ----------------------------------------------------- |
| `locker`   |      | a file locker for the running thread                  |
| `count`    |      | the number of bytes requested, or 0 if not applicable |
| `src_file` |      | the source file name                                  |
| `src_line` |      | the source line number                                |
| `locker`   |      | a file locker for the running thread                  |
| `count`    |      | the number of bytes requested, or 0 if not applicable |
| `src_file` |      | the source file name                                  |
| `src_line` |      | the source line number                                |

***

### end\_file\_wait\_v1\_t

```cpp
using end_file_wait_v1_t = void(*
```

Defined in psi/psi.h:1970

Record a file instrumentation end event. Note that for file close operations, the instrumented file handle associated with the file (which was provided to obtain a locker) is invalid after this call. **See also**: get\_thread\_file\_name\_locker

**See also**: get\_thread\_file\_stream\_locker

**See also**: get\_thread\_file\_descriptor\_locker

#### Parameters

| Parameter | Type | Description                                                                                               |
| --------- | ---- | --------------------------------------------------------------------------------------------------------- |
| `locker`  |      | a file locker for the running thread                                                                      |
| `count`   |      | the number of bytes actually used in the operation, or 0 if not applicable, or -1 if the operation failed |
| `locker`  |      | a file locker for the running thread                                                                      |
| `count`   |      | the number of bytes actually used in the operation, or 0 if not applicable, or -1 if the operation failed |

***

### start\_file\_close\_wait\_v1\_t

```cpp
using start_file_close_wait_v1_t = void(*
```

Defined in psi/psi.h:1979

Start a file instrumentation close operation.

#### Parameters

| Parameter  | Type | Description            |
| ---------- | ---- | ---------------------- |
| `locker`   |      | the file locker        |
| `src_file` |      | the source file name   |
| `src_line` |      | the source line number |
| `locker`   |      | the file locker        |
| `src_file` |      | the source file name   |
| `src_line` |      | the source line number |

***

### end\_file\_close\_wait\_v1\_t

```cpp
using end_file_close_wait_v1_t = void(*
```

Defined in psi/psi.h:1988

End a file instrumentation close operation.

#### Returns

an instrumented file handle

#### Parameters

| Parameter | Type | Description                                      |
| --------- | ---- | ------------------------------------------------ |
| `locker`  |      | the file locker.                                 |
| `rc`      |      | the close operation return code (0 for success). |
| `locker`  |      | the file locker.                                 |
| `rc`      |      | the close operation return code (0 for success). |

***

### end\_file\_rename\_wait\_v1\_t

```cpp
using end_file_rename_wait_v1_t = void(*
```

Defined in psi/psi.h:1998

Rename a file instrumentation close operation.

#### Parameters

| Parameter  | Type | Description                                       |
| ---------- | ---- | ------------------------------------------------- |
| `locker`   |      | the file locker.                                  |
| `old_name` |      | name of the file to be renamed.                   |
| `new_name` |      | name of the file after rename.                    |
| `rc`       |      | the rename operation return code (0 for success). |
| `locker`   |      | the file locker.                                  |
| `old_name` |      | name of the file to be renamed.                   |
| `new_name` |      | name of the file after rename.                    |
| `rc`       |      | the rename operation return code (0 for success). |

***

### start\_stage\_v1\_t

```cpp
using start_stage_v1_t = PSI_stage_progress *(*
```

Defined in psi/psi.h:2009

Start a new stage, and implicitly end the previous stage.

#### Returns

the new stage progress

#### Parameters

| Parameter  | Type | Description              |
| ---------- | ---- | ------------------------ |
| `key`      |      | the key of the new stage |
| `src_file` |      | the source file name     |
| `src_line` |      | the source line number   |
| `key`      |      | the key of the new stage |
| `src_file` |      | the source file name     |
| `src_line` |      | the source line number   |

***

### get\_current\_stage\_progress\_v1\_t

```cpp
using get_current_stage_progress_v1_t = PSI_stage_progress *(*
```

Defined in psi/psi.h:2012

***

### end\_stage\_v1\_t

```cpp
using end_stage_v1_t = void(*
```

Defined in psi/psi.h:2015

End the current stage.

***

### get\_thread\_statement\_locker\_v1\_t

```cpp
using get_thread_statement_locker_v1_t = struct PSI_statement_locker *(*
```

Defined in psi/psi.h:2015

Get a statement instrumentation locker.

#### Returns

a statement locker, or NULL

#### Parameters

| Parameter  | Type | Description                       |
| ---------- | ---- | --------------------------------- |
| `state`    |      | data storage for the locker       |
| `key`      |      | the statement instrumentation key |
| `charset`  |      | client character set              |
| `sp_share` |      | the share                         |
| `state`    |      | data storage for the locker       |
| `key`      |      | the statement instrumentation key |
| `charset`  |      | client character set              |
| `sp_share` |      | the share                         |

***

### refine\_statement\_v1\_t

```cpp
using refine_statement_v1_t = struct PSI_statement_locker *(*
```

Defined in psi/psi.h:2015

Refine a statement locker to a more specific key. Note that only events declared mutable can be refined. **See also**: [PSI\_FLAG\_MUTABLE](#psi_flag_mutable)

#### Parameters

| Parameter | Type | Description                            |
| --------- | ---- | -------------------------------------- |
| `locker`  |      | statement locker for the current event |
| `key`     |      | the new key for the event              |
| `locker`  |      | statement locker for the current event |
| `key`     |      | the new key for the event              |

***

### start\_statement\_v1\_t

```cpp
using start_statement_v1_t = void(*
```

Defined in psi/psi.h:2048

Start a new statement event.

#### Parameters

| Parameter   | Type | Description                                        |
| ----------- | ---- | -------------------------------------------------- |
| `locker`    |      | the statement locker for this event                |
| `db`        |      | the active database name for this statement        |
| `db_length` |      | the active database name length for this statement |
| `src_file`  |      | source file name                                   |
| `src_line`  |      | source line number                                 |
| `locker`    |      | the statement locker for this event                |
| `db`        |      | the active database name for this statement        |
| `db_length` |      | the active database name length for this statement |
| `src_file`  |      | source file name                                   |
| `src_line`  |      | source line number                                 |

***

### set\_statement\_text\_v1\_t

```cpp
using set_statement_text_v1_t = void(*
```

Defined in psi/psi.h:2059

Set the statement text for a statement event.

#### Parameters

| Parameter  | Type | Description                  |
| ---------- | ---- | ---------------------------- |
| `locker`   |      | the current statement locker |
| `text`     |      | the statement text           |
| `text_len` |      | the statement text length    |
| `locker`   |      | the current statement locker |
| `text`     |      | the statement text           |
| `text_len` |      | the statement text length    |

***

### set\_statement\_lock\_time\_t

```cpp
using set_statement_lock_time_t = void(*
```

Defined in psi/psi.h:2068

Set a statement event lock time.

#### Parameters

| Parameter   | Type | Description                      |
| ----------- | ---- | -------------------------------- |
| `locker`    |      | the statement locker             |
| `lock_time` |      | the locked time, in microseconds |
| `locker`    |      | the statement locker             |
| `lock_time` |      | the locked time, in microseconds |

***

### set\_statement\_rows\_sent\_t

```cpp
using set_statement_rows_sent_t = void(*
```

Defined in psi/psi.h:2076

Set a statement event rows sent metric.

#### Parameters

| Parameter | Type | Description             |
| --------- | ---- | ----------------------- |
| `locker`  |      | the statement locker    |
| `count`   |      | the number of rows sent |
| `locker`  |      | the statement locker    |
| `count`   |      | the number of rows sent |

***

### set\_statement\_rows\_examined\_t

```cpp
using set_statement_rows_examined_t = void(*
```

Defined in psi/psi.h:2084

Set a statement event rows examined metric.

#### Parameters

| Parameter | Type | Description                 |
| --------- | ---- | --------------------------- |
| `locker`  |      | the statement locker        |
| `count`   |      | the number of rows examined |
| `locker`  |      | the statement locker        |
| `count`   |      | the number of rows examined |

***

### inc\_statement\_created\_tmp\_disk\_tables\_t

```cpp
using inc_statement_created_tmp_disk_tables_t = void(*
```

Defined in psi/psi.h:2092

Increment a statement event "created tmp disk tables" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_created\_tmp\_tables\_t

```cpp
using inc_statement_created_tmp_tables_t = void(*
```

Defined in psi/psi.h:2100

Increment a statement event "created tmp tables" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_select\_full\_join\_t

```cpp
using inc_statement_select_full_join_t = void(*
```

Defined in psi/psi.h:2108

Increment a statement event "select full join" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_select\_full\_range\_join\_t

```cpp
using inc_statement_select_full_range_join_t = void(*
```

Defined in psi/psi.h:2116

Increment a statement event "select full range join" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_select\_range\_t

```cpp
using inc_statement_select_range_t = void(*
```

Defined in psi/psi.h:2124

Increment a statement event "select range join" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_select\_range\_check\_t

```cpp
using inc_statement_select_range_check_t = void(*
```

Defined in psi/psi.h:2132

Increment a statement event "select range check" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_select\_scan\_t

```cpp
using inc_statement_select_scan_t = void(*
```

Defined in psi/psi.h:2140

Increment a statement event "select scan" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_sort\_merge\_passes\_t

```cpp
using inc_statement_sort_merge_passes_t = void(*
```

Defined in psi/psi.h:2148

Increment a statement event "sort merge passes" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_sort\_range\_t

```cpp
using inc_statement_sort_range_t = void(*
```

Defined in psi/psi.h:2156

Increment a statement event "sort range" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_sort\_rows\_t

```cpp
using inc_statement_sort_rows_t = void(*
```

Defined in psi/psi.h:2164

Increment a statement event "sort rows" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### inc\_statement\_sort\_scan\_t

```cpp
using inc_statement_sort_scan_t = void(*
```

Defined in psi/psi.h:2172

Increment a statement event "sort scan" metric.

#### Parameters

| Parameter | Type | Description                |
| --------- | ---- | -------------------------- |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |
| `locker`  |      | the statement locker       |
| `count`   |      | the metric increment value |

***

### set\_statement\_no\_index\_used\_t

```cpp
using set_statement_no_index_used_t = void(*
```

Defined in psi/psi.h:2179

Set a statement event "no index used" metric.

#### Parameters

| Parameter | Type | Description          |
| --------- | ---- | -------------------- |
| `locker`  |      | the statement locker |
| `locker`  |      | the statement locker |

***

### set\_statement\_no\_good\_index\_used\_t

```cpp
using set_statement_no_good_index_used_t = void(*
```

Defined in psi/psi.h:2186

Set a statement event "no good index used" metric.

#### Parameters

| Parameter | Type | Description          |
| --------- | ---- | -------------------- |
| `locker`  |      | the statement locker |
| `locker`  |      | the statement locker |

***

### end\_statement\_v1\_t

```cpp
using end_statement_v1_t = void(*
```

Defined in psi/psi.h:2195

End a statement event. **See also**: Diagnostics\_area

#### Parameters

| Parameter | Type | Description                     |
| --------- | ---- | ------------------------------- |
| `locker`  |      | the statement locker            |
| `stmt_da` |      | the statement diagnostics area. |
| `locker`  |      | the statement locker            |
| `stmt_da` |      | the statement diagnostics area. |

***

### get\_thread\_transaction\_locker\_v1\_t

```cpp
using get_thread_transaction_locker_v1_t = struct PSI_transaction_locker *(*
```

Defined in psi/psi.h:2195

Get a transaction instrumentation locker.

#### Returns

a transaction locker, or NULL

#### Parameters

| Parameter         | Type | Description                                  |
| ----------------- | ---- | -------------------------------------------- |
| `state`           |      | data storage for the locker                  |
| `xid`             |      | the xid for this transaction                 |
| `trxid`           |      | the InnoDB transaction id                    |
| `isolation_level` |      | isolation level for this transaction         |
| `read_only`       |      | true if transaction access mode is read-only |
| `autocommit`      |      | true if transaction is autocommit            |
| `state`           |      | data storage for the locker                  |
| `xid`             |      | the xid for this transaction                 |
| `trxid`           |      | the InnoDB transaction id                    |
| `isolation_level` |      | isolation level for this transaction         |
| `read_only`       |      | true if transaction access mode is read-only |
| `autocommit`      |      | true if transaction is autocommit            |

***

### start\_transaction\_v1\_t

```cpp
using start_transaction_v1_t = void(*
```

Defined in psi/psi.h:2219

Start a new transaction event.

#### Parameters

| Parameter  | Type | Description                           |
| ---------- | ---- | ------------------------------------- |
| `locker`   |      | the transaction locker for this event |
| `src_file` |      | source file name                      |
| `src_line` |      | source line number                    |
| `locker`   |      | the transaction locker for this event |
| `src_file` |      | source file name                      |
| `src_line` |      | source line number                    |

***

### set\_transaction\_xid\_v1\_t

```cpp
using set_transaction_xid_v1_t = void(*
```

Defined in psi/psi.h:2229

Set the transaction xid.

#### Parameters

| Parameter  | Type | Description                           |
| ---------- | ---- | ------------------------------------- |
| `locker`   |      | the transaction locker for this event |
| `xid`      |      | the id of the XA transaction          |
| `xa_state` |      | is the state of the XA transaction    |
| `locker`   |      | the transaction locker for this event |
| `xid`      |      | the id of the XA transaction          |
| `xa_state` |      | is the state of the XA transaction    |

***

### set\_transaction\_xa\_state\_v1\_t

```cpp
using set_transaction_xa_state_v1_t = void(*
```

Defined in psi/psi.h:2238

Set the state of the XA transaction.

#### Parameters

| Parameter  | Type | Description                           |
| ---------- | ---- | ------------------------------------- |
| `locker`   |      | the transaction locker for this event |
| `xa_state` |      | the new state of the xa transaction   |
| `locker`   |      | the transaction locker for this event |
| `xa_state` |      | the new state of the xa transaction   |

***

### set\_transaction\_gtid\_v1\_t

```cpp
using set_transaction_gtid_v1_t = void(*
```

Defined in psi/psi.h:2248

Set the transaction gtid.

#### Parameters

| Parameter   | Type | Description                                          |
| ----------- | ---- | ---------------------------------------------------- |
| `locker`    |      | the transaction locker for this event                |
| `sid`       |      | the source id for the transaction, mapped from sidno |
| `gtid_spec` |      | the gtid specifier for the transaction               |
| `locker`    |      | the transaction locker for this event                |
| `sid`       |      | the source id for the transaction, mapped from sidno |
| `gtid_spec` |      | the gtid specifier for the transaction               |

***

### set\_transaction\_trxid\_v1\_t

```cpp
using set_transaction_trxid_v1_t = void(*
```

Defined in psi/psi.h:2257

Set the transaction trx\_id.

#### Parameters

| Parameter | Type | Description                           |
| --------- | ---- | ------------------------------------- |
| `locker`  |      | the transaction locker for this event |
| `trxid`   |      | the storage engine transaction ID     |
| `locker`  |      | the transaction locker for this event |
| `trxid`   |      | the storage engine transaction ID     |

***

### inc\_transaction\_savepoints\_v1\_t

```cpp
using inc_transaction_savepoints_v1_t = void(*
```

Defined in psi/psi.h:2266

Increment a transaction event savepoint count.

#### Parameters

| Parameter | Type | Description            |
| --------- | ---- | ---------------------- |
| `locker`  |      | the transaction locker |
| `count`   |      | the increment value    |
| `locker`  |      | the transaction locker |
| `count`   |      | the increment value    |

***

### inc\_transaction\_rollback\_to\_savepoint\_v1\_t

```cpp
using inc_transaction_rollback_to_savepoint_v1_t = void(*
```

Defined in psi/psi.h:2274

Increment a transaction event rollback to savepoint count.

#### Parameters

| Parameter | Type | Description            |
| --------- | ---- | ---------------------- |
| `locker`  |      | the transaction locker |
| `count`   |      | the increment value    |
| `locker`  |      | the transaction locker |
| `count`   |      | the increment value    |

***

### inc\_transaction\_release\_savepoint\_v1\_t

```cpp
using inc_transaction_release_savepoint_v1_t = void(*
```

Defined in psi/psi.h:2282

Increment a transaction event release savepoint count.

#### Parameters

| Parameter | Type | Description            |
| --------- | ---- | ---------------------- |
| `locker`  |      | the transaction locker |
| `count`   |      | the increment value    |
| `locker`  |      | the transaction locker |
| `count`   |      | the increment value    |

***

### end\_transaction\_v1\_t

```cpp
using end_transaction_v1_t = void(*
```

Defined in psi/psi.h:2290

Commit or rollback the transaction.

#### Parameters

| Parameter | Type | Description                                             |
| --------- | ---- | ------------------------------------------------------- |
| `locker`  |      | the transaction locker for this event                   |
| `commit`  |      | true if transaction was committed, false if rolled back |
| `locker`  |      | the transaction locker for this event                   |
| `commit`  |      | true if transaction was committed, false if rolled back |

***

### start\_socket\_wait\_v1\_t

```cpp
using start_socket_wait_v1_t = struct PSI_socket_locker *(*
```

Defined in psi/psi.h:2290

Record a socket instrumentation start event.

#### Parameters

| Parameter  | Type | Description                                           |
| ---------- | ---- | ----------------------------------------------------- |
| `state`    |      | locker state for the running thread                   |
| `socket`   |      | the instrumented socket                               |
| `op`       |      | socket operation to be performed                      |
| `count`    |      | the number of bytes requested, or 0 if not applicable |
| `src_file` |      | the source file name                                  |
| `src_line` |      | the source line number                                |
| `state`    |      | locker state for the running thread                   |
| `socket`   |      | the instrumented socket                               |
| `op`       |      | socket operation to be performed                      |
| `count`    |      | the number of bytes requested, or 0 if not applicable |
| `src_file` |      | the source file name                                  |
| `src_line` |      | the source line number                                |

***

### end\_socket\_wait\_v1\_t

```cpp
using end_socket_wait_v1_t = void(*
```

Defined in psi/psi.h:2320

Record a socket instrumentation end event. Note that for socket close operations, the instrumented socket handle associated with the socket (which was provided to obtain a locker) is invalid after this call. **See also**: get\_thread\_socket\_locker

#### Parameters

| Parameter | Type | Description                                                                                               |
| --------- | ---- | --------------------------------------------------------------------------------------------------------- |
| `locker`  |      | a socket locker for the running thread                                                                    |
| `count`   |      | the number of bytes actually used in the operation, or 0 if not applicable, or -1 if the operation failed |
| `locker`  |      | a socket locker for the running thread                                                                    |
| `count`   |      | the number of bytes actually used in the operation, or 0 if not applicable, or -1 if the operation failed |

***

### set\_socket\_state\_v1\_t

```cpp
using set_socket_state_v1_t = void(*
```

Defined in psi/psi.h:2328

Set the socket state for an instrumented socket.

#### Parameters

| Parameter | Type | Description             |
| --------- | ---- | ----------------------- |
| `socket`  |      | the instrumented socket |
| `state`   |      | socket state            |
| `socket`  |      | the instrumented socket |
| `state`   |      | socket state            |

***

### set\_socket\_info\_v1\_t

```cpp
using set_socket_info_v1_t = void(*
```

Defined in psi/psi.h:2338

Set the socket info for an instrumented socket.

#### Parameters

| Parameter  | Type | Description                 |
| ---------- | ---- | --------------------------- |
| `socket`   |      | the instrumented socket     |
| `fd`       |      | the socket descriptor       |
| `addr`     |      | the socket ip address       |
| `addr_len` |      | length of socket ip address |
| `socket`   |      | the instrumented socket     |
| `fd`       |      | the socket descriptor       |
| `addr`     |      | the socket ip address       |
| `addr_len` |      | length of socket ip address |

***

### set\_socket\_thread\_owner\_v1\_t

```cpp
using set_socket_thread_owner_v1_t = void(*
```

Defined in psi/psi.h:2347

Bind a socket to the thread that owns it.

#### Parameters

| Parameter | Type | Description         |
| --------- | ---- | ------------------- |
| `socket`  |      | instrumented socket |
| `socket`  |      | instrumented socket |

***

### create\_prepared\_stmt\_v1\_t

```cpp
using create_prepared_stmt_v1_t = PSI_prepared_stmt *(*
```

Defined in psi/psi.h:2352

Get a prepare statement.

***

### destroy\_prepared\_stmt\_v1\_t

```cpp
using destroy_prepared_stmt_v1_t = void(*
```

Defined in psi/psi.h:2360

destroy a prepare statement.

#### Parameters

| Parameter       | Type | Description         |
| --------------- | ---- | ------------------- |
| `prepared_stmt` |      | prepared statement. |
| `prepared_stmt` |      | prepared statement. |

***

### reprepare\_prepared\_stmt\_v1\_t

```cpp
using reprepare_prepared_stmt_v1_t = void(*
```

Defined in psi/psi.h:2367

reprepare a prepare statement.

#### Parameters

| Parameter       | Type | Description         |
| --------------- | ---- | ------------------- |
| `prepared_stmt` |      | prepared statement. |
| `prepared_stmt` |      | prepared statement. |

***

### execute\_prepared\_stmt\_v1\_t

```cpp
using execute_prepared_stmt_v1_t = void(*
```

Defined in psi/psi.h:2375

Record a prepare statement instrumentation execute event.

#### Parameters

| Parameter       | Type | Description                                |
| --------------- | ---- | ------------------------------------------ |
| `locker`        |      | a statement locker for the running thread. |
| `prepared_stmt` |      | prepared statement.                        |
| `locker`        |      | a statement locker for the running thread. |
| `prepared_stmt` |      | prepared statement.                        |

***

### set\_prepared\_stmt\_text\_v1\_t

```cpp
using set_prepared_stmt_text_v1_t = void(*
```

Defined in psi/psi.h:2384

Set the statement text for a prepared statement event.

#### Parameters

| Parameter       | Type | Description                        |
| --------------- | ---- | ---------------------------------- |
| `prepared_stmt` |      | prepared statement.                |
| `text`          |      | the prepared statement text        |
| `text_len`      |      | the prepared statement text length |
| `prepared_stmt` |      | prepared statement.                |
| `text`          |      | the prepared statement text        |
| `text_len`      |      | the prepared statement text length |

***

### digest\_start\_v1\_t

```cpp
using digest_start_v1_t = struct PSI_digest_locker *(*
```

Defined in psi/psi.h:2384

Get a digest locker for the current statement.

#### Parameters

| Parameter | Type | Description                               |
| --------- | ---- | ----------------------------------------- |
| `locker`  |      | a statement locker for the running thread |
| `locker`  |      | a statement locker for the running thread |

***

### digest\_end\_v1\_t

```cpp
using digest_end_v1_t = void(*
```

Defined in psi/psi.h:2399

Add a token to the current digest instrumentation.

#### Parameters

| Parameter | Type | Description                               |
| --------- | ---- | ----------------------------------------- |
| `locker`  |      | a digest locker for the current statement |
| `digest`  |      | The digest storage to add the token to    |
| `locker`  |      | a digest locker for the current statement |
| `digest`  |      | The digest storage to add the token to    |

***

### start\_sp\_v1\_t

```cpp
using start_sp_v1_t = PSI_sp_locker *(*
```

Defined in psi/psi.h:2402

***

### end\_sp\_v1\_t

```cpp
using end_sp_v1_t = void(*
```

Defined in psi/psi.h:2405

***

### drop\_sp\_v1\_t

```cpp
using drop_sp_v1_t = void(*
```

Defined in psi/psi.h:2408

***

### get\_sp\_share\_v1\_t

```cpp
using get_sp_share_v1_t = struct PSI_sp_share *(*
```

Defined in psi/psi.h:2408

Acquire a sp share instrumentation.

#### Returns

a stored program share instrumentation, or NULL

#### Parameters

| Parameter            | Type | Description       |
| -------------------- | ---- | ----------------- |
| `object_type`        |      | of stored program |
| `schema_name`        |      | of stored program |
| `schema_name_length` |      | of stored program |
| `object_name`        |      | of stored program |
| `object_name_length` |      | of stored program |
| `object_type`        |      | of stored program |
| `schema_name`        |      | of stored program |
| `schema_name_length` |      | of stored program |
| `object_name`        |      | of stored program |
| `object_name_length` |      | of stored program |

***

### release\_sp\_share\_v1\_t

```cpp
using release_sp_share_v1_t = void(*
```

Defined in psi/psi.h:2431

Release a stored program share.

#### Parameters

| Parameter | Type | Description                         |
| --------- | ---- | ----------------------------------- |
| `share`   |      | the stored program share to release |
| `share`   |      | the stored program share to release |

***

### create\_metadata\_lock\_v1\_t

```cpp
using create_metadata_lock_v1_t = PSI_metadata_lock *(*
```

Defined in psi/psi.h:2433

***

### set\_metadata\_lock\_status\_v1\_t

```cpp
using set_metadata_lock_status_v1_t = void(*
```

Defined in psi/psi.h:2442

***

### destroy\_metadata\_lock\_v1\_t

```cpp
using destroy_metadata_lock_v1_t = void(*
```

Defined in psi/psi.h:2445

***

### start\_metadata\_wait\_v1\_t

```cpp
using start_metadata_wait_v1_t = struct PSI_metadata_locker *(*
```

Defined in psi/psi.h:2445

***

### end\_metadata\_wait\_v1\_t

```cpp
using end_metadata_wait_v1_t = void(*
```

Defined in psi/psi.h:2452

***

### set\_thread\_connect\_attrs\_v1\_t

```cpp
using set_thread_connect_attrs_v1_t = int(*
```

Defined in psi/psi.h:2465

Stores an array of connection attributes

#### Returns

state

#### Parameters

| Parameter | Type | Description                                                          |
| --------- | ---- | -------------------------------------------------------------------- |
| `buffer`  |      | char array of length encoded connection attributes in network format |
| `length`  |      | length of the data in buffer                                         |
| `from_cs` |      | charset in which `buffer` is encoded                                 |
| `buffer`  |      | char array of length encoded connection attributes in network format |
| `length`  |      | length of the data in buffer                                         |
| `from_cs` |      | charset in which `buffer` is encoded                                 |

#### Return Values

| Value   | Description          |
| ------- | -------------------- |
| `non_0` | attributes truncated |
| `0`     | stored the attribute |

***

### PSI

```cpp
using PSI = struct PSI_v1
```

Type: struct [`PSI_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_v1)

Defined in psi/psi.h:2930

The instrumentation interface for the current version. **See also**: PSI\_CURRENT\_VERSION

***

### PSI\_mutex\_info

```cpp
using PSI_mutex_info = struct PSI_mutex_info_v1
```

Type: struct [`PSI_mutex_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_mutex_info_v1-1)

Defined in psi/psi.h:2931

The mutex information structure for the current version.

***

### PSI\_rwlock\_info

```cpp
using PSI_rwlock_info = struct PSI_rwlock_info_v1
```

Type: struct [`PSI_rwlock_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_rwlock_info_v1-1)

Defined in psi/psi.h:2932

The rwlock information structure for the current version.

***

### PSI\_cond\_info

```cpp
using PSI_cond_info = struct PSI_cond_info_v1
```

Type: struct [`PSI_cond_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_cond_info_v1-1)

Defined in psi/psi.h:2933

The cond information structure for the current version.

***

### PSI\_thread\_info

```cpp
using PSI_thread_info = struct PSI_thread_info_v1
```

Type: struct [`PSI_thread_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_thread_info_v1-1)

Defined in psi/psi.h:2934

The thread information structure for the current version.

***

### PSI\_file\_info

```cpp
using PSI_file_info = struct PSI_file_info_v1
```

Type: struct [`PSI_file_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_file_info_v1-1)

Defined in psi/psi.h:2935

The file information structure for the current version.

***

### PSI\_stage\_info

```cpp
using PSI_stage_info = struct PSI_stage_info_v1
```

Type: struct [`PSI_stage_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_stage_info_v1-1)

Defined in psi/psi.h:2936

The stage instrumentation has to co exist with the legacy THD::set\_proc\_info instrumentation. To avoid duplication of the instrumentation in the server, the common PSI\_stage\_info structure is used, so we export it here, even when not building with HAVE\_PSI\_INTERFACE.

***

### PSI\_statement\_info

```cpp
using PSI_statement_info = struct PSI_statement_info_v1
```

Type: struct [`PSI_statement_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_statement_info_v1-1)

Defined in psi/psi.h:2937

***

### PSI\_transaction\_info

```cpp
using PSI_transaction_info = struct PSI_transaction_info_v1
```

Defined in psi/psi.h:2938

***

### PSI\_socket\_info

```cpp
using PSI_socket_info = struct PSI_socket_info_v1
```

Type: struct [`PSI_socket_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_socket_info_v1-1)

Defined in psi/psi.h:2939

***

### PSI\_idle\_locker\_state

```cpp
using PSI_idle_locker_state = struct PSI_idle_locker_state_v1
```

Type: struct [`PSI_idle_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_idle_locker_state_v1-1)

Defined in psi/psi.h:2940

***

### PSI\_mutex\_locker\_state

```cpp
using PSI_mutex_locker_state = struct PSI_mutex_locker_state_v1
```

Type: struct [`PSI_mutex_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_mutex_locker_state_v1-1)

Defined in psi/psi.h:2941

***

### PSI\_rwlock\_locker\_state

```cpp
using PSI_rwlock_locker_state = struct PSI_rwlock_locker_state_v1
```

Type: struct [`PSI_rwlock_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_rwlock_locker_state_v1-1)

Defined in psi/psi.h:2942

***

### PSI\_cond\_locker\_state

```cpp
using PSI_cond_locker_state = struct PSI_cond_locker_state_v1
```

Type: struct [`PSI_cond_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_cond_locker_state_v1-1)

Defined in psi/psi.h:2943

***

### PSI\_file\_locker\_state

```cpp
using PSI_file_locker_state = struct PSI_file_locker_state_v1
```

Type: struct [`PSI_file_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_file_locker_state_v1-1)

Defined in psi/psi.h:2944

***

### PSI\_statement\_locker\_state

```cpp
using PSI_statement_locker_state = struct PSI_statement_locker_state_v1
```

Type: struct [`PSI_statement_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_statement_locker_state_v1-1)

Defined in psi/psi.h:2945

***

### PSI\_transaction\_locker\_state

```cpp
using PSI_transaction_locker_state = struct PSI_transaction_locker_state_v1
```

Type: struct [`PSI_transaction_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_transaction_locker_state_v1-1)

Defined in psi/psi.h:2946

***

### PSI\_socket\_locker\_state

```cpp
using PSI_socket_locker_state = struct PSI_socket_locker_state_v1
```

Type: struct [`PSI_socket_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_socket_locker_state_v1-1)

Defined in psi/psi.h:2947

***

### PSI\_sp\_locker\_state

```cpp
using PSI_sp_locker_state = struct PSI_sp_locker_state_v1
```

Type: struct [`PSI_sp_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_sp_locker_state_v1-1)

Defined in psi/psi.h:2948

***

### PSI\_metadata\_locker\_state

```cpp
using PSI_metadata_locker_state = struct PSI_metadata_locker_state_v1
```

Type: struct [`PSI_metadata_locker_state_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_metadata_locker_state_v1-1)

Defined in psi/psi.h:2949

***

### PSI\_metadata\_locker

```cpp
using PSI_metadata_locker = struct PSI_stage_info_none
```

Type: struct [`PSI_stage_info_none`](/docs/server/reference/plugins/api-plugin/instrumentation_interface.md#psi_stage_info_none)

Defined in psi/psi.h:3015

***

### MYSQL\_THD

```cpp
using MYSQL_THD = struct THD *
```

Type: struct [`THD`](#thd) \*

Defined in plugin.h:54

***

### my\_bool

```cpp
using my_bool = char
```

Defined in plugin.h:57

***

### MYSQL\_PLUGIN

```cpp
using MYSQL_PLUGIN = void *
```

Defined in plugin.h:58

***

### MYSQL\_XID

```cpp
using MYSQL_XID = struct st_mysql_xid
```

Type: struct [`st_mysql_xid`](#st_mysql_xid)

Defined in plugin.h:77

***

### mysql\_show\_var\_func

```cpp
using mysql_show_var_func = int(*
```

Defined in plugin.h:215

***

### mysql\_var\_check\_func

```cpp
using mysql_var_check_func = int(*
```

Defined in plugin.h:284

SYNOPSIS (\*mysql\_var\_check\_func)() thd thread handle var dynamic variable being altered save pointer to temporary storage value user provided value RETURN 0 user provided value is OK and the update func may be called. any other value indicates error.

This function should parse the user provided value and store in the provided temporary storage any data as required by the update func. There is sufficient space in the temporary storage to store a double. Note that the update func may not be called if any other error occurs so any memory allocated should be thread-local so that it may be freed automatically at the end of the statement.

***

### mysql\_var\_update\_func

```cpp
using mysql_var_update_func = void(*
```

Defined in plugin.h:302

SYNOPSIS (\*mysql\_var\_update\_func)() thd thread handle var dynamic variable being altered var\_ptr pointer to dynamic variable save pointer to temporary storage RETURN NONE

This function should use the validated value stored in the temporary store and persist it in the provided pointer to the dynamic variable. For example, strings may require memory to be allocated.

***

### PSI\_memory\_key

```cpp
using PSI_memory_key = unsigned int
```

Defined in psi/psi\_base.h:177

Instrumented memory key. To instrument memory, a memory key must be obtained using `register_memory`. Using a zero key always disable the instrumentation.

***

### MYSQL\_FILE

```cpp
using MYSQL_FILE = struct st_mysql_file
```

Type: struct [`st_mysql_file`](/docs/server/reference/plugins/api-plugin/file_instrumentation.md#st_mysql_file)

Defined in psi/mysql\_file.h:515

Type of an instrumented file. `MYSQL_FILE` is a drop-in replacement for `FILE`. **See also**: [mysql\_file\_open](#mysql_file_open)

***

### PSI\_memory\_info\_v1

```cpp
using PSI_memory_info_v1 = struct PSI_memory_info_v1
```

Type: struct [`PSI_memory_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_memory_info_v1-1)

Defined in psi/psi\_memory.h:80

***

### register\_memory\_v1\_t

```cpp
using register_memory_v1_t = void(*
```

Defined in psi/psi\_memory.h:88

Memory registration API.

#### Parameters

| Parameter  | Type | Description                               |
| ---------- | ---- | ----------------------------------------- |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of memory info to register       |
| `count`    |      | the size of the info array                |
| `category` |      | a category name (typically a plugin name) |
| `info`     |      | an array of memory info to register       |
| `count`    |      | the size of the info array                |

***

### memory\_alloc\_v1\_t

```cpp
using memory_alloc_v1_t = PSI_memory_key(*
```

Defined in psi/psi\_memory.h:98

Instrument memory allocation.

#### Returns

the effective memory instrument key

#### Parameters

| Parameter | Type | Description                  |
| --------- | ---- | ---------------------------- |
| `key`     |      | the memory instrument key    |
| `size`    |      | the size of memory allocated |
| `owner`   |      | the memory owner             |
| `key`     |      | the memory instrument key    |
| `size`    |      | the size of memory allocated |
| `owner`   |      | the memory owner             |

***

### memory\_realloc\_v1\_t

```cpp
using memory_realloc_v1_t = PSI_memory_key(*
```

Defined in psi/psi\_memory.h:109

Instrument memory re allocation.

#### Returns

the effective memory instrument key

#### Parameters

| Parameter  | Type | Description                             |
| ---------- | ---- | --------------------------------------- |
| `key`      |      | the memory instrument key               |
| `old_size` |      | the size of memory previously allocated |
| `new_size` |      | the size of memory re allocated         |
| `owner`    |      | the memory owner                        |
| `key`      |      | the memory instrument key               |
| `old_size` |      | the size of memory previously allocated |
| `new_size` |      | the size of memory re allocated         |
| `owner`    |      | the memory owner                        |

***

### memory\_claim\_v1\_t

```cpp
using memory_claim_v1_t = PSI_memory_key(*
```

Defined in psi/psi\_memory.h:119

Instrument memory claim.

#### Returns

the effective memory instrument key

#### Parameters

| Parameter | Type | Description                  |
| --------- | ---- | ---------------------------- |
| `key`     |      | the memory instrument key    |
| `size`    |      | the size of memory allocated |
| `owner`   |      | the memory owner             |
| `key`     |      | the memory instrument key    |
| `size`    |      | the size of memory allocated |
| `owner`   |      | the memory owner             |

***

### memory\_free\_v1\_t

```cpp
using memory_free_v1_t = void(*
```

Defined in psi/psi\_memory.h:128

Instrument memory free.

#### Parameters

| Parameter | Type | Description                  |
| --------- | ---- | ---------------------------- |
| `key`     |      | the memory instrument key    |
| `size`    |      | the size of memory allocated |
| `owner`   |      | the memory owner             |
| `key`     |      | the memory instrument key    |
| `size`    |      | the size of memory allocated |
| `owner`   |      | the memory owner             |

***

### PSI\_memory\_info

```cpp
using PSI_memory_info = struct PSI_memory_info_v1
```

Type: struct [`PSI_memory_info_v1`](/docs/server/reference/plugins/api-plugin/group_psi_v1.md#psi_memory_info_v1-1)

Defined in psi/psi\_memory.h:148

***

### MYSQL\_SERVER\_AUTH\_INFO

```cpp
using MYSQL_SERVER_AUTH_INFO = struct st_mysql_server_auth_info
```

Type: struct [`st_mysql_server_auth_info`](#st_mysql_server_auth_info)

Defined in plugin\_auth.h:114

Provides server plugin access to authentication information

***

### MYSQL\_SOCKET

```cpp
using MYSQL_SOCKET = struct st_mysql_socket
```

Type: struct [`st_mysql_socket`](/docs/server/reference/plugins/api-plugin/socket_instrumentation.md#st_mysql_socket)

Defined in psi/mysql\_socket.h:99

An instrumented socket. `MYSQL_SOCKET` is a replacement for `my_socket`.

***

### mysql\_mutex\_t

```cpp
using mysql_mutex_t = struct st_mysql_mutex
```

Type: struct [`st_mysql_mutex`](/docs/server/reference/plugins/api-plugin/thread_instrumentation.md#st_mysql_mutex)

Defined in psi/mysql\_thread.h:159

Type of an instrumented mutex. `mysql_mutex_t` is a drop-in replacement for `pthread_mutex_t`. **See also**: [mysql\_mutex\_assert\_owner](#mysql_mutex_assert_owner)

**See also**: [mysql\_mutex\_assert\_not\_owner](#mysql_mutex_assert_not_owner)

**See also**: [mysql\_mutex\_init](#mysql_mutex_init)

**See also**: [mysql\_mutex\_lock](#mysql_mutex_lock)

**See also**: [mysql\_mutex\_unlock](#mysql_mutex_unlock)

**See also**: [mysql\_mutex\_destroy](#mysql_mutex_destroy)

***

### mysql\_rwlock\_t

```cpp
using mysql_rwlock_t = struct st_mysql_rwlock
```

Type: struct [`st_mysql_rwlock`](/docs/server/reference/plugins/api-plugin/thread_instrumentation.md#st_mysql_rwlock)

Defined in psi/mysql\_thread.h:204

Type of an instrumented rwlock. `mysql_rwlock_t` is a drop-in replacement for `pthread_rwlock_t`. **See also**: [mysql\_rwlock\_init](#mysql_rwlock_init)

**See also**: [mysql\_rwlock\_rdlock](#mysql_rwlock_rdlock)

**See also**: [mysql\_rwlock\_tryrdlock](#mysql_rwlock_tryrdlock)

**See also**: [mysql\_rwlock\_wrlock](#mysql_rwlock_wrlock)

**See also**: [mysql\_rwlock\_trywrlock](#mysql_rwlock_trywrlock)

**See also**: [mysql\_rwlock\_unlock](#mysql_rwlock_unlock)

**See also**: [mysql\_rwlock\_destroy](#mysql_rwlock_destroy)

***

### mysql\_prlock\_t

```cpp
using mysql_prlock_t = struct st_mysql_prlock
```

Type: struct [`st_mysql_prlock`](/docs/server/reference/plugins/api-plugin/thread_instrumentation.md#st_mysql_prlock)

Defined in psi/mysql\_thread.h:216

Type of an instrumented prlock. A prlock is a read write lock that 'prefers readers' (pr). `mysql_prlock_t` is a drop-in replacement for `rw_pr_lock_t`. **See also**: [mysql\_prlock\_init](#mysql_prlock_init)

**See also**: [mysql\_prlock\_rdlock](#mysql_prlock_rdlock)

**See also**: [mysql\_prlock\_wrlock](#mysql_prlock_wrlock)

**See also**: [mysql\_prlock\_unlock](#mysql_prlock_unlock)

**See also**: [mysql\_prlock\_destroy](#mysql_prlock_destroy)

***

### mysql\_cond\_t

```cpp
using mysql_cond_t = struct st_mysql_cond
```

Type: struct [`st_mysql_cond`](/docs/server/reference/plugins/api-plugin/thread_instrumentation.md#st_mysql_cond)

Defined in psi/mysql\_thread.h:244

Type of an instrumented condition. `mysql_cond_t` is a drop-in replacement for `pthread_cond_t`. **See also**: [mysql\_cond\_init](#mysql_cond_init)

**See also**: [mysql\_cond\_wait](#mysql_cond_wait)

**See also**: [mysql\_cond\_timedwait](#mysql_cond_timedwait)

**See also**: [mysql\_cond\_signal](#mysql_cond_signal)

**See also**: [mysql\_cond\_broadcast](#mysql_cond_broadcast)

**See also**: [mysql\_cond\_destroy](#mysql_cond_destroy)

***

### query\_id\_t

```cpp
using query_id_t = int64
```

Defined in service\_wsrep.h:53

***

### LOGGER\_HANDLE

```cpp
using LOGGER_HANDLE = struct logger_handle_st
```

Defined in service\_logger.h:61

***

### MYSQL\_FTPARSER\_BOOLEAN\_INFO

```cpp
using MYSQL_FTPARSER_BOOLEAN_INFO = struct st_mysql_ftparser_boolean_info
```

Type: struct [`st_mysql_ftparser_boolean_info`](#st_mysql_ftparser_boolean_info)

Defined in plugin\_ftparser.h:130

***

### MYSQL\_FTPARSER\_PARAM

```cpp
using MYSQL_FTPARSER_PARAM = struct st_mysql_ftparser_param
```

Type: struct [`st_mysql_ftparser_param`](#st_mysql_ftparser_param)

Defined in plugin\_ftparser.h:198

***

### CHARSET\_INFO

```cpp
using CHARSET_INFO = const struct charset_info_st
```

Defined in psi/mysql\_statement.h:35

***

### thd\_wait\_type

```cpp
using thd_wait_type = enum _thd_wait_type_e
```

Type: enum [`_thd_wait_type_e`](#thd_wait_type_e)

Defined in service\_thd\_wait.h:79

***

### MYSQL\_CONST\_LEX\_STRING

```cpp
using MYSQL_CONST_LEX_STRING = struct st_mysql_const_lex_string
```

Type: struct [`st_mysql_const_lex_string`](#st_mysql_const_lex_string)

Defined in service\_thd\_alloc.h:43

***

### MYSQL\_LEX\_STRING

```cpp
using MYSQL_LEX_STRING = struct st_mysql_lex_string
```

Type: struct [`st_mysql_lex_string`](#st_mysql_lex_string)

Defined in service\_thd\_alloc.h:57

***

### mysql\_authentication\_dialog\_ask\_t

```cpp
using mysql_authentication_dialog_ask_t = char *(*
```

Defined in auth\_dialog\_client.h:43

type of the mysql\_authentication\_dialog\_ask function

#### Parameters

| Parameter | Type | Description                                                     |
| --------- | ---- | --------------------------------------------------------------- |
| `mysql`   |      | mysql                                                           |
| `type`    |      | type of the input 1 - ordinary string input 2 - password string |
| `prompt`  |      | prompt                                                          |
| `buf`     |      | a buffer to store the use input                                 |
| `buf_len` |      | the length of the buffer                                        |

#### Return Values

| Value | Description                                                                                                                                                                             |
| ----- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `a`   | pointer to the user input string. It may be equal to 'buf' or to 'mysql->password'. In all other cases it is assumed to be an allocated string, and the "dialog" plugin will free() it. |

***

### MYSQL\_PLUGIN\_VIO\_INFO

```cpp
using MYSQL_PLUGIN_VIO_INFO = struct st_plugin_vio_info
```

Type: struct [`st_plugin_vio_info`](#st_plugin_vio_info)

Defined in plugin\_auth\_common.h:102

***

### MYSQL\_PLUGIN\_VIO

```cpp
using MYSQL_PLUGIN_VIO = struct st_plugin_vio
```

Type: struct [`st_plugin_vio`](#st_plugin_vio)

Defined in plugin\_auth\_common.h:131

Provides plugin access to communication channel

***

### MYSQL\_THD\_KEY\_T

```cpp
using MYSQL_THD_KEY_T = int
```

Defined in service\_thd\_specifics.h:60

## Functions

***

### SHOW\_FUNC\_ENTRY

`static` `inline`

```cpp
static inline struct st_mysql_show_var SHOW_FUNC_ENTRY(const char * name, mysql_show_var_func func_arg)
```

Defined in plugin.h:219

***

### thd\_in\_lock\_tables

```cpp
int thd_in_lock_tables(const MYSQL_THD thd)
```

Defined in plugin.h:696

***

### thd\_tablespace\_op

```cpp
int thd_tablespace_op(const MYSQL_THD thd)
```

Defined in plugin.h:697

***

### thd\_test\_options

```cpp
long long thd_test_options(const MYSQL_THD thd, long long test_options)
```

Defined in plugin.h:698

***

### thd\_sql\_command

```cpp
int thd_sql_command(const MYSQL_THD thd)
```

Defined in plugin.h:699

***

### thd\_ddl\_options

```cpp
struct DDL_options_st * thd_ddl_options(const MYSQL_THD thd)
```

Defined in plugin.h:701

***

### thd\_storage\_lock\_wait

```cpp
void thd_storage_lock_wait(MYSQL_THD thd, long long value)
```

Defined in plugin.h:702

***

### thd\_tx\_isolation

```cpp
int thd_tx_isolation(const MYSQL_THD thd)
```

Defined in plugin.h:703

***

### thd\_tx\_is\_read\_only

```cpp
int thd_tx_is_read_only(const MYSQL_THD thd)
```

Defined in plugin.h:704

***

### mysql\_tmpfile

```cpp
int mysql_tmpfile(const char * prefix)
```

Defined in plugin.h:718

Create a temporary file.

The temporary file is created in a location specified by the mysql server configuration (–tmpdir option). The caller does not need to delete the file, it will be deleted automatically.

#### Parameters

| Parameter | Type           | Description                    |
| --------- | -------------- | ------------------------------ |
| `prefix`  | `const char *` | prefix for temporary file name |

#### Return Values

| Value | Description                                            |
| ----- | ------------------------------------------------------ |
| `-1`  | error                                                  |
| `>=`  | 0 a file handle that can be passed to dup or my\_close |

***

### thd\_get\_thread\_id

```cpp
unsigned long thd_get_thread_id(const MYSQL_THD thd)
```

Defined in plugin.h:726

Return the thread id of a user thread

#### Returns

thread id

#### Parameters

| Parameter | Type                            | Description                   |
| --------- | ------------------------------- | ----------------------------- |
| `thd`     | const [`MYSQL_THD`](#mysql_thd) | user thread connection handle |

***

### thd\_get\_xid

```cpp
void thd_get_xid(const MYSQL_THD thd, MYSQL_XID * xid)
```

Defined in plugin.h:734

Get the XID for this connection's transaction

#### Parameters

| Parameter | Type                            | Description                         |
| --------- | ------------------------------- | ----------------------------------- |
| `thd`     | const [`MYSQL_THD`](#mysql_thd) | user thread connection handle       |
| `xid`     | [`MYSQL_XID`](#mysql_xid) \*    | location where identifier is stored |

***

### mysql\_query\_cache\_invalidate4

```cpp
void mysql_query_cache_invalidate4(MYSQL_THD thd, const char * key, unsigned int key_length, int using_trx)
```

Defined in plugin.h:744

Invalidate the query cache for a given table.

#### Parameters

| Parameter    | Type                      | Description                                       |
| ------------ | ------------------------- | ------------------------------------------------- |
| `thd`        | [`MYSQL_THD`](#mysql_thd) | user thread connection handle                     |
| `key`        | `const char *`            | databasename\0tablename\0                         |
| `key_length` | `unsigned int`            | length of key in bytes, including the NUL bytes   |
| `using_trx`  | `int`                     | flag: TRUE if using transactions, FALSE otherwise |

***

### thd\_get\_ha\_data

```cpp
void * thd_get_ha_data(const MYSQL_THD thd, const struct transaction_participant * hton)
```

Defined in plugin.h:752

Provide a handler data getter to simplify coding

***

### thd\_set\_ha\_data

```cpp
void thd_set_ha_data(MYSQL_THD thd, const struct transaction_participant * hton, const void * ha_data)
```

Defined in plugin.h:776

Provide a handler data setter to simplify coding

Set ha\_data pointer (storage engine per-connection information).

To avoid unclean deactivation (uninstall) of storage engine plugin in the middle of transaction, additional storage engine plugin lock is acquired.

If ha\_data is not null and storage engine plugin was not locked by [thd\_set\_ha\_data()](#thd_set_ha_data) in this connection before, storage engine plugin gets locked.

If ha\_data is null and storage engine plugin was locked by [thd\_set\_ha\_data()](#thd_set_ha_data) in this connection before, storage engine plugin lock gets released.

If transaction\_participant::close\_connection() didn't reset ha\_data, server does it immediately after calling transaction\_participant::close\_connection()

***

### thd\_wakeup\_subsequent\_commits

```cpp
void thd_wakeup_subsequent_commits(MYSQL_THD thd, int wakeup_error)
```

Defined in plugin.h:811

Signal that the first part of handler commit is finished, and that the committed transaction is now visible and has fixed commit ordering with respect to other transactions. The commit need *not* be durable yet, and typically will not be when this call makes sense.

This call is optional, if the storage engine does not call it the upper layer will after the handler commit() method is done. However, the storage engine may choose to call it itself to increase the possibility for group commit.

In-order parallel replication uses this to apply different transaction in parallel, but delay the commits of later transactions until earlier transactions have committed first, thus achieving increased performance on multi-core systems while still preserving full transaction consistency.

The storage engine can call this from within the commit() method, typically after the commit record has been written to the transaction log, but before the log has been fsync()'ed. This will allow the next replicated transaction to proceed to commit before the first one has done fsync() or similar. Thus, it becomes possible for multiple sequential replicated transactions to share a single fsync() inside the engine in group commit.

Note that this method should *not* be called from within the commit\_ordered() method, or any other place in the storage engine. When commit\_ordered() is used (typically when binlog is enabled), the transaction coordinator takes care of this and makes group commit in the storage engine possible without any other action needed on the part of the storage engine. This function [thd\_wakeup\_subsequent\_commits()](#thd_wakeup_subsequent_commits) is only needed when no transaction coordinator is used, meaning a single storage engine and no binary log.

***

### inline\_mysql\_file\_register

`static` `inline`

```cpp
static inline void inline_mysql_file_register(const char *category __attribute__, void *info __attribute__, int count __attribute__, const char *category __attribute__, void *info __attribute__, int count __attribute__)
```

Defined in psi/mysql\_file.h:517

***

### inline\_mysql\_file\_fgets

`static` `inline`

```cpp
static inline char * inline_mysql_file_fgets(char * str, int size, MYSQL_FILE * file, char * str, int size, MYSQL_FILE * file)
```

Defined in psi/mysql\_file.h:535

***

### inline\_mysql\_file\_fgetc

`static` `inline`

```cpp
static inline int inline_mysql_file_fgetc(MYSQL_FILE * file, MYSQL_FILE * file)
```

Defined in psi/mysql\_file.h:563

***

### inline\_mysql\_file\_fputs

`static` `inline`

```cpp
static inline int inline_mysql_file_fputs(const char * str, MYSQL_FILE * file, const char * str, MYSQL_FILE * file)
```

Defined in psi/mysql\_file.h:591

***

### inline\_mysql\_file\_fputc

`static` `inline`

```cpp
static inline int inline_mysql_file_fputc(char c, MYSQL_FILE * file, char c, MYSQL_FILE * file)
```

Defined in psi/mysql\_file.h:621

***

### inline\_mysql\_file\_fprintf

`static` `inline`

```cpp
static inline int inline_mysql_file_fprintf(MYSQL_FILE * file, const char * format, ..., MYSQL_FILE * file, const char * format, ...)
```

Defined in psi/mysql\_file.h:649

***

### inline\_mysql\_file\_vfprintf

`static` `inline`

```cpp
static inline int inline_mysql_file_vfprintf(MYSQL_FILE * file, const char * format, va_list args, MYSQL_FILE * file, const char * format, va_list args)
```

Defined in psi/mysql\_file.h:681

***

### inline\_mysql\_file\_fflush

`static` `inline`

```cpp
static inline int inline_mysql_file_fflush(MYSQL_FILE * file, MYSQL_FILE * file)
```

Defined in psi/mysql\_file.h:709

***

### inline\_mysql\_file\_feof

`static` `inline`

```cpp
static inline int inline_mysql_file_feof(MYSQL_FILE * file, MYSQL_FILE * file)
```

Defined in psi/mysql\_file.h:736

***

### inline\_mysql\_file\_fstat

`static` `inline`

```cpp
static inline int inline_mysql_file_fstat(int filenr, MY_STAT * stat_area, myf flags, int filenr, MY_STAT * stat_area, myf flags)
```

Defined in psi/mysql\_file.h:743

***

### inline\_mysql\_file\_stat

`static` `inline`

```cpp
static inline MY_STAT * inline_mysql_file_stat(const char * path, MY_STAT * stat_area, myf flags, const char * path, MY_STAT * stat_area, myf flags)
```

Defined in psi/mysql\_file.h:768

***

### inline\_mysql\_file\_chsize

`static` `inline`

```cpp
static inline int inline_mysql_file_chsize(File file, my_off_t newlength, int filler, myf flags, File file, my_off_t newlength, int filler, myf flags)
```

Defined in psi/mysql\_file.h:793

***

### inline\_mysql\_file\_fopen

`static` `inline`

```cpp
static inline MYSQL_FILE * inline_mysql_file_fopen(const char * filename, int flags, myf myFlags, const char * filename, int flags, myf myFlags)
```

Defined in psi/mysql\_file.h:819

***

### inline\_mysql\_file\_fclose

`static` `inline`

```cpp
static inline int inline_mysql_file_fclose(MYSQL_FILE * file, myf flags, MYSQL_FILE * file, myf flags)
```

Defined in psi/mysql\_file.h:861

***

### inline\_mysql\_file\_fread

`static` `inline`

```cpp
static inline size_t inline_mysql_file_fread(MYSQL_FILE * file, uchar * buffer, size_t count, myf flags, MYSQL_FILE * file, uchar * buffer, size_t count, myf flags)
```

Defined in psi/mysql\_file.h:895

***

### inline\_mysql\_file\_fwrite

`static` `inline`

```cpp
static inline size_t inline_mysql_file_fwrite(MYSQL_FILE * file, const uchar * buffer, size_t count, myf flags, MYSQL_FILE * file, const uchar * buffer, size_t count, myf flags)
```

Defined in psi/mysql\_file.h:928

***

### inline\_mysql\_file\_fseek

`static` `inline`

```cpp
static inline my_off_t inline_mysql_file_fseek(MYSQL_FILE * file, my_off_t pos, int whence, myf flags, MYSQL_FILE * file, my_off_t pos, int whence, myf flags)
```

Defined in psi/mysql\_file.h:961

***

### inline\_mysql\_file\_ftell

`static` `inline`

```cpp
static inline my_off_t inline_mysql_file_ftell(MYSQL_FILE * file, myf flags, MYSQL_FILE * file, myf flags)
```

Defined in psi/mysql\_file.h:989

***

### inline\_mysql\_file\_create

`static` `inline`

```cpp
static inline File inline_mysql_file_create(const char * filename, mode_t create_flags, int access_flags, myf myFlags, const char * filename, mode_t create_flags, int access_flags, myf myFlags)
```

Defined in psi/mysql\_file.h:1017

***

### inline\_mysql\_file\_create\_temp

`static` `inline`

```cpp
static inline File inline_mysql_file_create_temp(char * to, const char * dir, const char * pfx, int mode, myf myFlags, char * to, const char * dir, const char * pfx, int mode, myf myFlags)
```

Defined in psi/mysql\_file.h:1043

***

### inline\_mysql\_file\_open

`static` `inline`

```cpp
static inline File inline_mysql_file_open(const char * filename, int flags, myf myFlags, const char * filename, int flags, myf myFlags)
```

Defined in psi/mysql\_file.h:1070

***

### inline\_mysql\_file\_close

`static` `inline`

```cpp
static inline int inline_mysql_file_close(File file, myf flags, File file, myf flags)
```

Defined in psi/mysql\_file.h:1096

***

### inline\_mysql\_file\_read

`static` `inline`

```cpp
static inline size_t inline_mysql_file_read(File file, uchar * buffer, size_t count, myf flags, File file, uchar * buffer, size_t count, myf flags)
```

Defined in psi/mysql\_file.h:1121

***

### inline\_mysql\_file\_write

`static` `inline`

```cpp
static inline size_t inline_mysql_file_write(File file, const uchar * buffer, size_t count, myf flags, File file, const uchar * buffer, size_t count, myf flags)
```

Defined in psi/mysql\_file.h:1151

***

### inline\_mysql\_file\_pread

`static` `inline`

```cpp
static inline size_t inline_mysql_file_pread(File file, uchar * buffer, size_t count, my_off_t offset, myf flags, File file, uchar * buffer, size_t count, my_off_t offset, myf flags)
```

Defined in psi/mysql\_file.h:1181

***

### inline\_mysql\_file\_pwrite

`static` `inline`

```cpp
static inline size_t inline_mysql_file_pwrite(File file, const uchar * buffer, size_t count, my_off_t offset, myf flags, File file, const uchar * buffer, size_t count, my_off_t offset, myf flags)
```

Defined in psi/mysql\_file.h:1211

***

### inline\_mysql\_file\_seek

`static` `inline`

```cpp
static inline my_off_t inline_mysql_file_seek(File file, my_off_t pos, int whence, myf flags, File file, my_off_t pos, int whence, myf flags)
```

Defined in psi/mysql\_file.h:1241

***

### inline\_mysql\_file\_tell

`static` `inline`

```cpp
static inline my_off_t inline_mysql_file_tell(File file, myf flags, File file, myf flags)
```

Defined in psi/mysql\_file.h:1266

***

### inline\_mysql\_file\_delete

`static` `inline`

```cpp
static inline int inline_mysql_file_delete(const char * name, myf flags, const char * name, myf flags)
```

Defined in psi/mysql\_file.h:1291

***

### inline\_mysql\_file\_rename

`static` `inline`

```cpp
static inline int inline_mysql_file_rename(const char * from, const char * to, myf flags, const char * from, const char * to, myf flags)
```

Defined in psi/mysql\_file.h:1316

***

### inline\_mysql\_file\_create\_with\_symlink

`static` `inline`

```cpp
static inline File inline_mysql_file_create_with_symlink(const char * linkname, const char * filename, mode_t create_flags, int access_flags, myf flags, const char * linkname, const char * filename, mode_t create_flags, int access_flags, myf flags)
```

Defined in psi/mysql\_file.h:1343

***

### inline\_mysql\_file\_delete\_with\_symlink

`static` `inline`

```cpp
static inline int inline_mysql_file_delete_with_symlink(const char * name, const char * ext, myf flags, const char * name, const char * ext, myf flags)
```

Defined in psi/mysql\_file.h:1373

***

### inline\_mysql\_file\_rename\_with\_symlink

`static` `inline`

```cpp
static inline int inline_mysql_file_rename_with_symlink(const char * from, const char * to, myf flags, const char * from, const char * to, myf flags)
```

Defined in psi/mysql\_file.h:1402

***

### inline\_mysql\_file\_sync

`static` `inline`

```cpp
static inline int inline_mysql_file_sync(File fd, myf flags, File fd, myf flags)
```

Defined in psi/mysql\_file.h:1428

***

### my\_md5

```cpp
void my_md5(unsigned char *, const char *, size_t)
```

Defined in service\_md5.h:54

***

### my\_md5\_multi

```cpp
void my_md5_multi(unsigned char *, ...)
```

Defined in service\_md5.h:55

***

### my\_md5\_context\_size

```cpp
size_t my_md5_context_size()
```

Defined in service\_md5.h:56

***

### my\_md5\_init

```cpp
void my_md5_init(void * context)
```

Defined in service\_md5.h:57

***

### my\_md5\_input

```cpp
void my_md5_input(void * context, const unsigned char * buf, size_t len)
```

Defined in service\_md5.h:58

***

### my\_md5\_result

```cpp
void my_md5_result(void * context, unsigned char * digest)
```

Defined in service\_md5.h:59

***

### mysql\_real\_connect\_local

```cpp
MYSQL * mysql_real_connect_local(MYSQL * mysql)
```

Defined in service\_sql.h:112

***

### get\_current\_thd

```cpp
MYSQL_THD get_current_thd()
```

Defined in service\_thd.h:38

current thd accessor

#### Returns

pointer to current thd

***

### inline\_mysql\_memory\_register

`static` `inline`

```cpp
static inline void inline_mysql_memory_register(const char *category __attribute__, void *info __attribute__, int count __attribute__, const char *category __attribute__, void *info __attribute__, int count __attribute__)
```

Defined in psi/mysql\_memory.h:62

***

### mysql\_socket\_invalid

`static` `inline`

```cpp
static inline MYSQL_SOCKET mysql_socket_invalid()
```

Defined in psi/mysql\_socket.h:115

MYSQL\_SOCKET helper. Initialize instrumented socket. **See also**: mysql\_socket\_getfd

**See also**: mysql\_socket\_setfd

***

### mysql\_socket\_set\_address

`static` `inline`

```cpp
static inline void mysql_socket_set_address(MYSQL_SOCKET socket, const struct sockaddr * addr, socklen_t addr_len, MYSQL_SOCKET socket, const struct sockaddr * addr, socklen_t addr_len)
```

Defined in psi/mysql\_socket.h:130

Set socket descriptor and address.

#### Parameters

| Parameter  | Type                            | Description                |
| ---------- | ------------------------------- | -------------------------- |
| `socket`   | [`MYSQL_SOCKET`](#mysql_socket) | instrumented socket        |
| `addr`     | `const struct sockaddr *`       | unformatted socket address |
| `addr_len` | `socklen_t`                     | length of socket address   |
| `socket`   | [`MYSQL_SOCKET`](#mysql_socket) | instrumented socket        |
| `addr`     | `const struct sockaddr *`       | unformatted socket address |
| `addr_len` | `socklen_t`                     | length of socket address   |

***

### mysql\_socket\_set\_thread\_owner

`static` `inline`

```cpp
static inline void mysql_socket_set_thread_owner(MYSQL_SOCKET socket, MYSQL_SOCKET socket)
```

Defined in psi/mysql\_socket.h:153

Set socket descriptor and address.

#### Parameters

| Parameter | Type                            | Description         |
| --------- | ------------------------------- | ------------------- |
| `socket`  | [`MYSQL_SOCKET`](#mysql_socket) | instrumented socket |
| `socket`  | [`MYSQL_SOCKET`](#mysql_socket) | instrumented socket |

***

### mysql\_socket\_getfd

`static` `inline`

```cpp
static inline my_socket mysql_socket_getfd(MYSQL_SOCKET mysql_socket, MYSQL_SOCKET mysql_socket)
```

Defined in psi/mysql\_socket.h:173

MYSQL\_SOCKET helper. Get socket descriptor. **See also**: mysql\_socket\_getfd

#### Parameters

| Parameter      | Type                            | Description         |
| -------------- | ------------------------------- | ------------------- |
| `mysql_socket` | [`MYSQL_SOCKET`](#mysql_socket) | Instrumented socket |
| `mysql_socket` | [`MYSQL_SOCKET`](#mysql_socket) | Instrumented socket |

***

### mysql\_socket\_setfd

`static` `inline`

```cpp
static inline void mysql_socket_setfd(MYSQL_SOCKET * mysql_socket, my_socket fd, MYSQL_SOCKET * mysql_socket, my_socket fd)
```

Defined in psi/mysql\_socket.h:185

MYSQL\_SOCKET helper. Set socket descriptor. **See also**: mysql\_socket\_setfd

#### Parameters

| Parameter      | Type                               | Description         |
| -------------- | ---------------------------------- | ------------------- |
| `mysql_socket` | [`MYSQL_SOCKET`](#mysql_socket) \* | Instrumented socket |
| `fd`           | `my_socket`                        | Socket descriptor   |
| `mysql_socket` | [`MYSQL_SOCKET`](#mysql_socket) \* | Instrumented socket |
| `fd`           | `my_socket`                        | Socket descriptor   |

***

### inline\_mysql\_start\_socket\_wait

`static` `inline`

```cpp
static inline struct PSI_socket_locker * inline_mysql_start_socket_wait(PSI_socket_locker_state * state, MYSQL_SOCKET mysql_socket, enum PSI_socket_operation op, size_t byte_count, const char * src_file, uint src_line, PSI_socket_locker_state * state, MYSQL_SOCKET mysql_socket, enum PSI_socket_operation op, size_t byte_count, const char * src_file, uint src_line)
```

Defined in psi/mysql\_socket.h:266

Instrumentation calls for MYSQL\_START\_SOCKET\_WAIT. **See also**: [MYSQL\_START\_SOCKET\_WAIT](#mysql_start_socket_wait).

***

### inline\_mysql\_end\_socket\_wait

`static` `inline`

```cpp
static inline void inline_mysql_end_socket_wait(struct PSI_socket_locker * locker, size_t byte_count, struct PSI_socket_locker * locker, size_t byte_count)
```

Defined in psi/mysql\_socket.h:288

Instrumentation calls for MYSQL\_END\_SOCKET\_WAIT. **See also**: [MYSQL\_END\_SOCKET\_WAIT](#mysql_end_socket_wait).

***

### inline\_mysql\_socket\_set\_state

`static` `inline`

```cpp
static inline void inline_mysql_socket_set_state(MYSQL_SOCKET socket, enum PSI_socket_state state, MYSQL_SOCKET socket, enum PSI_socket_state state)
```

Defined in psi/mysql\_socket.h:301

Set the state (IDLE, ACTIVE) of an instrumented socket. **See also**: PSI\_socket\_state

#### Parameters

| Parameter | Type                            | Description             |
| --------- | ------------------------------- | ----------------------- |
| `socket`  | [`MYSQL_SOCKET`](#mysql_socket) | the instrumented socket |
| `state`   | `enum PSI_socket_state`         | the new state           |
| `socket`  | [`MYSQL_SOCKET`](#mysql_socket) | the instrumented socket |
| `state`   | `enum PSI_socket_state`         | the new state           |

***

### inline\_mysql\_socket\_register

`static` `inline`

```cpp
static inline void inline_mysql_socket_register(const char * category, PSI_socket_info * info, int count, const char * category, PSI_socket_info * info, int count)
```

Defined in psi/mysql\_socket.h:589

***

### inline\_mysql\_socket\_fd

`static` `inline`

```cpp
static inline MYSQL_SOCKET inline_mysql_socket_fd(PSI_socket_key key, int fd, PSI_socket_key key, int fd)
```

Defined in psi/mysql\_socket.h:601

mysql\_socket\_fd

***

### inline\_mysql\_socket\_socket

`static` `inline`

```cpp
static inline MYSQL_SOCKET inline_mysql_socket_socket(PSI_socket_key key, int domain, int type, int protocol, PSI_socket_key key, int domain, int type, int protocol)
```

Defined in psi/mysql\_socket.h:634

mysql\_socket\_socket

***

### inline\_mysql\_socket\_bind

`static` `inline`

```cpp
static inline int inline_mysql_socket_bind(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const struct sockaddr * addr, size_t len, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const struct sockaddr * addr, size_t len)
```

Defined in psi/mysql\_socket.h:663

mysql\_socket\_bind

***

### inline\_mysql\_socket\_getsockname

`static` `inline`

```cpp
static inline int inline_mysql_socket_getsockname(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, struct sockaddr * addr, socklen_t * len, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, struct sockaddr * addr, socklen_t * len)
```

Defined in psi/mysql\_socket.h:703

mysql\_socket\_getsockname

***

### inline\_mysql\_socket\_connect

`static` `inline`

```cpp
static inline int inline_mysql_socket_connect(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const struct sockaddr * addr, socklen_t len, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const struct sockaddr * addr, socklen_t len)
```

Defined in psi/mysql\_socket.h:741

mysql\_socket\_connect

***

### inline\_mysql\_socket\_getpeername

`static` `inline`

```cpp
static inline int inline_mysql_socket_getpeername(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, struct sockaddr * addr, socklen_t * len, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, struct sockaddr * addr, socklen_t * len)
```

Defined in psi/mysql\_socket.h:779

mysql\_socket\_getpeername

***

### inline\_mysql\_socket\_send

`static` `inline`

```cpp
static inline ssize_t inline_mysql_socket_send(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const SOCKBUF_T * buf, size_t n, int flags, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const SOCKBUF_T * buf, size_t n, int flags)
```

Defined in psi/mysql\_socket.h:817

mysql\_socket\_send

***

### inline\_mysql\_socket\_recv

`static` `inline`

```cpp
static inline ssize_t inline_mysql_socket_recv(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, SOCKBUF_T * buf, size_t n, int flags, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, SOCKBUF_T * buf, size_t n, int flags)
```

Defined in psi/mysql\_socket.h:858

mysql\_socket\_recv

***

### inline\_mysql\_socket\_sendto

`static` `inline`

```cpp
static inline ssize_t inline_mysql_socket_sendto(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const SOCKBUF_T * buf, size_t n, int flags, const struct sockaddr * addr, socklen_t addr_len, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const SOCKBUF_T * buf, size_t n, int flags, const struct sockaddr * addr, socklen_t addr_len)
```

Defined in psi/mysql\_socket.h:899

mysql\_socket\_sendto

***

### inline\_mysql\_socket\_recvfrom

`static` `inline`

```cpp
static inline ssize_t inline_mysql_socket_recvfrom(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, SOCKBUF_T * buf, size_t n, int flags, struct sockaddr * addr, socklen_t * addr_len, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, SOCKBUF_T * buf, size_t n, int flags, struct sockaddr * addr, socklen_t * addr_len)
```

Defined in psi/mysql\_socket.h:940

mysql\_socket\_recvfrom

***

### inline\_mysql\_socket\_getsockopt

`static` `inline`

```cpp
static inline int inline_mysql_socket_getsockopt(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int level, int optname, SOCKBUF_T * optval, socklen_t * optlen, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int level, int optname, SOCKBUF_T * optval, socklen_t * optlen)
```

Defined in psi/mysql\_socket.h:982

mysql\_socket\_getsockopt

***

### inline\_mysql\_socket\_setsockopt

`static` `inline`

```cpp
static inline int inline_mysql_socket_setsockopt(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int level, int optname, const SOCKBUF_T * optval, socklen_t optlen, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int level, int optname, const SOCKBUF_T * optval, socklen_t optlen)
```

Defined in psi/mysql\_socket.h:1020

mysql\_socket\_setsockopt

***

### set\_socket\_nonblock

`static` `inline`

```cpp
static inline int set_socket_nonblock(my_socket fd, my_socket fd)
```

Defined in psi/mysql\_socket.h:1058

set\_socket\_nonblock

***

### inline\_mysql\_sock\_set\_nonblocking

`static` `inline`

```cpp
static inline int inline_mysql_sock_set_nonblocking(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket)
```

Defined in psi/mysql\_socket.h:1091

mysql\_socket\_set\_nonblocking

***

### inline\_mysql\_socket\_listen

`static` `inline`

```cpp
static inline int inline_mysql_socket_listen(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int backlog, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int backlog)
```

Defined in psi/mysql\_socket.h:1131

mysql\_socket\_listen

***

### inline\_mysql\_socket\_accept

`static` `inline`

```cpp
static inline MYSQL_SOCKET inline_mysql_socket_accept(const char * src_file, uint src_line, PSI_socket_key key, MYSQL_SOCKET socket_listen, struct sockaddr * addr, socklen_t * addr_len, const char * src_file, uint src_line, PSI_socket_key key, MYSQL_SOCKET socket_listen, struct sockaddr * addr, socklen_t * addr_len)
```

Defined in psi/mysql\_socket.h:1169

mysql\_socket\_accept

***

### inline\_mysql\_socket\_close

`static` `inline`

```cpp
static inline int inline_mysql_socket_close(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket)
```

Defined in psi/mysql\_socket.h:1250

mysql\_socket\_close

***

### inline\_mysql\_socket\_shutdown

`static` `inline`

```cpp
static inline int inline_mysql_socket_shutdown(const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int how, const char * src_file, uint src_line, MYSQL_SOCKET mysql_socket, int how)
```

Defined in psi/mysql\_socket.h:1291

mysql\_socket\_shutdown

***

### inline\_mysql\_mutex\_register

`static` `inline`

```cpp
static inline void inline_mysql_mutex_register(const char *category __attribute__, void *info __attribute__, int count __attribute__, const char *category __attribute__, void *info __attribute__, int count __attribute__)
```

Defined in psi/mysql\_thread.h:669

***

### inline\_mysql\_mutex\_init

`static` `inline`

```cpp
static inline int inline_mysql_mutex_init(mysql_mutex_t * that, const pthread_mutexattr_t * attr, mysql_mutex_t * that, const pthread_mutexattr_t * attr)
```

Defined in psi/mysql\_thread.h:686

***

### inline\_mysql\_mutex\_destroy

`static` `inline`

```cpp
static inline int inline_mysql_mutex_destroy(mysql_mutex_t * that, mysql_mutex_t * that)
```

Defined in psi/mysql\_thread.h:709

***

### inline\_mysql\_mutex\_lock

`static` `inline`

```cpp
static inline int inline_mysql_mutex_lock(mysql_mutex_t * that, mysql_mutex_t * that)
```

Defined in psi/mysql\_thread.h:737

***

### inline\_mysql\_mutex\_trylock

`static` `inline`

```cpp
static inline int inline_mysql_mutex_trylock(mysql_mutex_t * that, mysql_mutex_t * that)
```

Defined in psi/mysql\_thread.h:756

***

### inline\_mysql\_mutex\_unlock

`static` `inline`

```cpp
static inline int inline_mysql_mutex_unlock(mysql_mutex_t * that, mysql_mutex_t * that)
```

Defined in psi/mysql\_thread.h:775

***

### inline\_mysql\_rwlock\_register

`static` `inline`

```cpp
static inline void inline_mysql_rwlock_register(const char *category __attribute__, void *info __attribute__, int count __attribute__, const char *category __attribute__, void *info __attribute__, int count __attribute__)
```

Defined in psi/mysql\_thread.h:798

***

### inline\_mysql\_rwlock\_init

`static` `inline`

```cpp
static inline int inline_mysql_rwlock_init(mysql_rwlock_t * that, mysql_rwlock_t * that)
```

Defined in psi/mysql\_thread.h:815

***

### inline\_mysql\_prlock\_init

`static` `inline`

```cpp
static inline int inline_mysql_prlock_init(mysql_prlock_t * that, mysql_prlock_t * that)
```

Defined in psi/mysql\_thread.h:833

***

### inline\_mysql\_rwlock\_destroy

`static` `inline`

```cpp
static inline int inline_mysql_rwlock_destroy(mysql_rwlock_t * that, mysql_rwlock_t * that)
```

Defined in psi/mysql\_thread.h:848

***

### inline\_mysql\_prlock\_destroy

`static` `inline`

```cpp
static inline int inline_mysql_prlock_destroy(mysql_prlock_t * that, mysql_prlock_t * that)
```

Defined in psi/mysql\_thread.h:862

***

### inline\_mysql\_rwlock\_rdlock

`static` `inline`

```cpp
static inline int inline_mysql_rwlock_rdlock(mysql_rwlock_t * that, mysql_rwlock_t * that)
```

Defined in psi/mysql\_thread.h:893

***

### inline\_mysql\_prlock\_rdlock

`static` `inline`

```cpp
static inline int inline_mysql_prlock_rdlock(mysql_prlock_t * that, mysql_prlock_t * that)
```

Defined in psi/mysql\_thread.h:908

***

### inline\_mysql\_rwlock\_wrlock

`static` `inline`

```cpp
static inline int inline_mysql_rwlock_wrlock(mysql_rwlock_t * that, mysql_rwlock_t * that)
```

Defined in psi/mysql\_thread.h:923

***

### inline\_mysql\_prlock\_wrlock

`static` `inline`

```cpp
static inline int inline_mysql_prlock_wrlock(mysql_prlock_t * that, mysql_prlock_t * that)
```

Defined in psi/mysql\_thread.h:938

***

### inline\_mysql\_rwlock\_tryrdlock

`static` `inline`

```cpp
static inline int inline_mysql_rwlock_tryrdlock(mysql_rwlock_t * that, mysql_rwlock_t * that)
```

Defined in psi/mysql\_thread.h:953

***

### inline\_mysql\_rwlock\_trywrlock

`static` `inline`

```cpp
static inline int inline_mysql_rwlock_trywrlock(mysql_rwlock_t * that, mysql_rwlock_t * that)
```

Defined in psi/mysql\_thread.h:967

***

### inline\_mysql\_rwlock\_unlock

`static` `inline`

```cpp
static inline int inline_mysql_rwlock_unlock(mysql_rwlock_t * that, mysql_rwlock_t * that)
```

Defined in psi/mysql\_thread.h:981

***

### inline\_mysql\_prlock\_unlock

`static` `inline`

```cpp
static inline int inline_mysql_prlock_unlock(mysql_prlock_t * that, mysql_prlock_t * that)
```

Defined in psi/mysql\_thread.h:994

***

### inline\_mysql\_cond\_register

`static` `inline`

```cpp
static inline void inline_mysql_cond_register(const char *category __attribute__, void *info __attribute__, int count __attribute__, const char *category __attribute__, void *info __attribute__, int count __attribute__)
```

Defined in psi/mysql\_thread.h:1007

***

### inline\_mysql\_cond\_init

`static` `inline`

```cpp
static inline int inline_mysql_cond_init(mysql_cond_t * that, const pthread_condattr_t * attr, mysql_cond_t * that, const pthread_condattr_t * attr)
```

Defined in psi/mysql\_thread.h:1024

***

### inline\_mysql\_cond\_destroy

`static` `inline`

```cpp
static inline int inline_mysql_cond_destroy(mysql_cond_t * that, mysql_cond_t * that)
```

Defined in psi/mysql\_thread.h:1039

***

### inline\_mysql\_cond\_wait

`static` `inline`

```cpp
static inline int inline_mysql_cond_wait(mysql_cond_t * that, mysql_mutex_t * mutex, mysql_cond_t * that, mysql_mutex_t * mutex)
```

Defined in psi/mysql\_thread.h:1060

***

### inline\_mysql\_cond\_timedwait

`static` `inline`

```cpp
static inline int inline_mysql_cond_timedwait(mysql_cond_t * that, mysql_mutex_t * mutex, const struct timespec * abstime, mysql_cond_t * that, mysql_mutex_t * mutex, const struct timespec * abstime)
```

Defined in psi/mysql\_thread.h:1075

***

### inline\_mysql\_cond\_signal

`static` `inline`

```cpp
static inline int inline_mysql_cond_signal(mysql_cond_t * that, mysql_cond_t * that)
```

Defined in psi/mysql\_thread.h:1091

***

### inline\_mysql\_cond\_broadcast

`static` `inline`

```cpp
static inline int inline_mysql_cond_broadcast(mysql_cond_t * that, mysql_cond_t * that)
```

Defined in psi/mysql\_thread.h:1103

***

### inline\_mysql\_thread\_register

`static` `inline`

```cpp
static inline void inline_mysql_thread_register(const char *category __attribute__, void *info __attribute__, int count __attribute__, const char *category __attribute__, void *info __attribute__, int count __attribute__)
```

Defined in psi/mysql\_thread.h:1115

***

### json\_type

```cpp
enum json_types json_type(const char * js, const char * js_end, const char ** value, int * value_len)
```

Defined in service\_json.h:94

***

### json\_get\_array\_item

```cpp
enum json_types json_get_array_item(const char * js, const char * js_end, int n_item, const char ** value, int * value_len)
```

Defined in service\_json.h:96

***

### json\_get\_object\_key

```cpp
enum json_types json_get_object_key(const char * js, const char * js_end, const char * key, const char ** value, int * value_len)
```

Defined in service\_json.h:99

***

### json\_get\_object\_nkey

```cpp
enum json_types json_get_object_nkey(const char * js, const char * js_end, int nkey, const char ** keyname, const char ** keyname_end, const char ** value, int * value_len)
```

Defined in service\_json.h:102

***

### json\_escape\_string

```cpp
int json_escape_string(const char * str, const char * str_end, char * json, char * json_end)
```

Defined in service\_json.h:105

***

### json\_unescape\_json

```cpp
int json_unescape_json(const char * json_str, const char * json_end, char * res, char * res_end)
```

Defined in service\_json.h:107

***

### my\_sha1

```cpp
void my_sha1(unsigned char *, const char *, size_t)
```

Defined in service\_sha1.h:54

***

### my\_sha1\_multi

```cpp
void my_sha1_multi(unsigned char *, ...)
```

Defined in service\_sha1.h:55

***

### my\_sha1\_context\_size

```cpp
size_t my_sha1_context_size()
```

Defined in service\_sha1.h:56

***

### my\_sha1\_init

```cpp
void my_sha1_init(void * context)
```

Defined in service\_sha1.h:57

***

### my\_sha1\_input

```cpp
void my_sha1_input(void * context, const unsigned char * buf, size_t len)
```

Defined in service\_sha1.h:58

***

### my\_sha1\_result

```cpp
void my_sha1_result(void * context, unsigned char * digest)
```

Defined in service\_sha1.h:59

***

### my\_sha224

```cpp
void my_sha224(unsigned char *, const char *, size_t)
```

Defined in service\_sha2.h:94

***

### my\_sha224\_multi

```cpp
void my_sha224_multi(unsigned char *, ...)
```

Defined in service\_sha2.h:95

***

### my\_sha224\_context\_size

```cpp
size_t my_sha224_context_size()
```

Defined in service\_sha2.h:96

***

### my\_sha224\_init

```cpp
void my_sha224_init(void * context)
```

Defined in service\_sha2.h:97

***

### my\_sha224\_input

```cpp
void my_sha224_input(void * context, const unsigned char * buf, size_t len)
```

Defined in service\_sha2.h:98

***

### my\_sha224\_result

```cpp
void my_sha224_result(void * context, unsigned char * digest)
```

Defined in service\_sha2.h:99

***

### my\_sha256

```cpp
void my_sha256(unsigned char *, const char *, size_t)
```

Defined in service\_sha2.h:101

***

### my\_sha256\_multi

```cpp
void my_sha256_multi(unsigned char *, ...)
```

Defined in service\_sha2.h:102

***

### my\_sha256\_context\_size

```cpp
size_t my_sha256_context_size()
```

Defined in service\_sha2.h:103

***

### my\_sha256\_init

```cpp
void my_sha256_init(void * context)
```

Defined in service\_sha2.h:104

***

### my\_sha256\_input

```cpp
void my_sha256_input(void * context, const unsigned char * buf, size_t len)
```

Defined in service\_sha2.h:105

***

### my\_sha256\_result

```cpp
void my_sha256_result(void * context, unsigned char * digest)
```

Defined in service\_sha2.h:106

***

### my\_sha384

```cpp
void my_sha384(unsigned char *, const char *, size_t)
```

Defined in service\_sha2.h:108

***

### my\_sha384\_multi

```cpp
void my_sha384_multi(unsigned char *, ...)
```

Defined in service\_sha2.h:109

***

### my\_sha384\_context\_size

```cpp
size_t my_sha384_context_size()
```

Defined in service\_sha2.h:110

***

### my\_sha384\_init

```cpp
void my_sha384_init(void * context)
```

Defined in service\_sha2.h:111

***

### my\_sha384\_input

```cpp
void my_sha384_input(void * context, const unsigned char * buf, size_t len)
```

Defined in service\_sha2.h:112

***

### my\_sha384\_result

```cpp
void my_sha384_result(void * context, unsigned char * digest)
```

Defined in service\_sha2.h:113

***

### my\_sha512

```cpp
void my_sha512(unsigned char *, const char *, size_t)
```

Defined in service\_sha2.h:115

***

### my\_sha512\_multi

```cpp
void my_sha512_multi(unsigned char *, ...)
```

Defined in service\_sha2.h:116

***

### my\_sha512\_context\_size

```cpp
size_t my_sha512_context_size()
```

Defined in service\_sha2.h:117

***

### my\_sha512\_init

```cpp
void my_sha512_init(void * context)
```

Defined in service\_sha2.h:118

***

### my\_sha512\_input

```cpp
void my_sha512_input(void * context, const unsigned char * buf, size_t len)
```

Defined in service\_sha2.h:119

***

### my\_sha512\_result

```cpp
void my_sha512_result(void * context, unsigned char * digest)
```

Defined in service\_sha2.h:120

***

### mysql\_load\_plugin

```cpp
struct st_mysql_client_plugin * mysql_load_plugin(struct st_mysql * mysql, const char * name, int type, int argc, ...)
```

Defined in client\_plugin.h:120

loads a plugin and initializes it

#### Parameters

| Parameter | Type                | Description                                                       |
| --------- | ------------------- | ----------------------------------------------------------------- |
| `mysql`   | `struct st_mysql *` | MYSQL structure.                                                  |
| `name`    | `const char *`      | a name of the plugin to load                                      |
| `type`    | `int`               | type of plugin that should be loaded, -1 to disable type check    |
| `argc`    | `int`               | number of arguments to pass to the plugin initialization function |

#### Return Values

| Value | Description                                                |
| ----- | ---------------------------------------------------------- |
| `a`   | pointer to the loaded plugin, or NULL in case of a failure |

***

### mysql\_load\_plugin\_v

```cpp
struct st_mysql_client_plugin * mysql_load_plugin_v(struct st_mysql * mysql, const char * name, int type, int argc, va_list args)
```

Defined in client\_plugin.h:140

loads a plugin and initializes it, taking va\_list as an argument

This is the same as mysql\_load\_plugin, but take va\_list instead of a list of arguments.

#### Parameters

| Parameter | Type                | Description                                                       |
| --------- | ------------------- | ----------------------------------------------------------------- |
| `mysql`   | `struct st_mysql *` | MYSQL structure.                                                  |
| `name`    | `const char *`      | a name of the plugin to load                                      |
| `type`    | `int`               | type of plugin that should be loaded, -1 to disable type check    |
| `argc`    | `int`               | number of arguments to pass to the plugin initialization function |
| `args`    | `va_list`           | arguments for the plugin initialization function                  |

#### Return Values

| Value | Description                                                |
| ----- | ---------------------------------------------------------- |
| `a`   | pointer to the loaded plugin, or NULL in case of a failure |

***

### mysql\_client\_find\_plugin

```cpp
struct st_mysql_client_plugin * mysql_client_find_plugin(struct st_mysql * mysql, const char * name, int type)
```

Defined in client\_plugin.h:154

finds an already loaded plugin by name, or loads it, if necessary

#### Parameters

| Parameter | Type                | Description                          |
| --------- | ------------------- | ------------------------------------ |
| `mysql`   | `struct st_mysql *` | MYSQL structure.                     |
| `name`    | `const char *`      | a name of the plugin to load         |
| `type`    | `int`               | type of plugin that should be loaded |

#### Return Values

| Value | Description                                         |
| ----- | --------------------------------------------------- |
| `a`   | pointer to the plugin, or NULL in case of a failure |

***

### mysql\_client\_register\_plugin

```cpp
struct st_mysql_client_plugin * mysql_client_register_plugin(struct st_mysql * mysql, struct st_mysql_client_plugin * plugin)
```

Defined in client\_plugin.h:171

adds a plugin structure to the list of loaded plugins

This is useful if an application has the necessary functionality (for example, a special load data handler) statically linked into the application binary. It can use this function to register the plugin directly, avoiding the need to factor it out into a shared object.

#### Parameters

| Parameter | Type                                                          | Description                                                                   |
| --------- | ------------------------------------------------------------- | ----------------------------------------------------------------------------- |
| `mysql`   | `struct st_mysql *`                                           | MYSQL structure. It is only used for error reporting                          |
| `plugin`  | struct [`st_mysql_client_plugin`](#st_mysql_client_plugin) \* | an [st\_mysql\_client\_plugin](#st_mysql_client_plugin) structure to register |

#### Return Values

| Value | Description                                         |
| ----- | --------------------------------------------------- |
| `a`   | pointer to the plugin, or NULL in case of a failure |

***

### mysql\_plugin\_options

```cpp
int mysql_plugin_options(struct st_mysql_client_plugin * plugin, const char * option, const void * value)
```

Defined in client\_plugin.h:186

set plugin options

Can be used to set extra options and affect behavior for a plugin. This function may be called multiple times to set several options

#### Parameters

| Parameter | Type                                                          | Description                                                       |
| --------- | ------------------------------------------------------------- | ----------------------------------------------------------------- |
| `plugin`  | struct [`st_mysql_client_plugin`](#st_mysql_client_plugin) \* | an [st\_mysql\_client\_plugin](#st_mysql_client_plugin) structure |
| `option`  | `const char *`                                                | a string which specifies the option to set                        |
| `value`   | `const void *`                                                | value for the option.                                             |

#### Return Values

| Value | Description                      |
| ----- | -------------------------------- |
| `0`   | on success, 1 in case of failure |

***

### wsrep\_consistency\_check

```cpp
bool wsrep_consistency_check(MYSQL_THD thd)
```

Defined in service\_wsrep.h:167

***

### wsrep\_prepare\_key\_for\_innodb

```cpp
bool wsrep_prepare_key_for_innodb(MYSQL_THD thd, const unsigned char * cache_key, size_t cache_key_len, const unsigned char * row_id, size_t row_id_len, struct wsrep_buf * key, size_t * key_len)
```

Defined in service\_wsrep.h:168

***

### wsrep\_thd\_query

```cpp
const char * wsrep_thd_query(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:169

***

### wsrep\_is\_wsrep\_xid

```cpp
int wsrep_is_wsrep_xid(const void * xid)
```

Defined in service\_wsrep.h:170

***

### wsrep\_xid\_seqno

```cpp
long long wsrep_xid_seqno(const struct xid_t * xid)
```

Defined in service\_wsrep.h:171

***

### wsrep\_xid\_uuid

```cpp
const unsigned char * wsrep_xid_uuid(const struct xid_t * xid)
```

Defined in service\_wsrep.h:172

***

### wsrep\_thd\_trx\_seqno

```cpp
long long wsrep_thd_trx_seqno(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:173

***

### get\_wsrep\_recovery

```cpp
my_bool get_wsrep_recovery()
```

Defined in service\_wsrep.h:174

***

### wsrep\_thd\_ignore\_table

```cpp
bool wsrep_thd_ignore_table(MYSQL_THD thd)
```

Defined in service\_wsrep.h:175

***

### wsrep\_set\_data\_home\_dir

```cpp
void wsrep_set_data_home_dir(const char * data_dir)
```

Defined in service\_wsrep.h:176

***

### wsrep\_on

```cpp
my_bool wsrep_on(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:184

***

### wsrep\_thd\_LOCK

```cpp
void wsrep_thd_LOCK(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:186

***

### wsrep\_thd\_TRYLOCK

```cpp
int wsrep_thd_TRYLOCK(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:188

***

### wsrep\_thd\_UNLOCK

```cpp
void wsrep_thd_UNLOCK(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:190

***

### wsrep\_thd\_kill\_LOCK

```cpp
void wsrep_thd_kill_LOCK(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:192

***

### wsrep\_thd\_kill\_UNLOCK

```cpp
void wsrep_thd_kill_UNLOCK(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:193

***

### wsrep\_thd\_client\_state\_str

```cpp
const char * wsrep_thd_client_state_str(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:196

***

### wsrep\_thd\_client\_mode\_str

```cpp
const char * wsrep_thd_client_mode_str(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:198

***

### wsrep\_thd\_transaction\_state\_str

```cpp
const char * wsrep_thd_transaction_state_str(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:200

***

### wsrep\_thd\_transaction\_id

```cpp
query_id_t wsrep_thd_transaction_id(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:203

***

### wsrep\_thd\_self\_abort

```cpp
void wsrep_thd_self_abort(MYSQL_THD thd)
```

Defined in service\_wsrep.h:205

***

### wsrep\_thd\_is\_local

```cpp
my_bool wsrep_thd_is_local(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:207

***

### wsrep\_thd\_is\_applying

```cpp
my_bool wsrep_thd_is_applying(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:210

***

### wsrep\_thd\_is\_toi

```cpp
my_bool wsrep_thd_is_toi(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:212

***

### wsrep\_thd\_is\_local\_toi

```cpp
my_bool wsrep_thd_is_local_toi(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:214

***

### wsrep\_thd\_is\_in\_rsu

```cpp
my_bool wsrep_thd_is_in_rsu(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:216

***

### wsrep\_thd\_is\_BF

```cpp
my_bool wsrep_thd_is_BF(const MYSQL_THD thd, my_bool sync)
```

Defined in service\_wsrep.h:218

***

### wsrep\_thd\_is\_SR

```cpp
my_bool wsrep_thd_is_SR(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:220

***

### wsrep\_handle\_SR\_rollback

```cpp
void wsrep_handle_SR_rollback(MYSQL_THD BF_thd, MYSQL_THD victim_thd)
```

Defined in service\_wsrep.h:221

***

### wsrep\_thd\_retry\_counter

```cpp
int wsrep_thd_retry_counter(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:223

***

### wsrep\_thd\_bf\_abort

```cpp
my_bool wsrep_thd_bf_abort(MYSQL_THD bf_thd, MYSQL_THD victim_thd, my_bool signal)
```

Defined in service\_wsrep.h:225

***

### wsrep\_thd\_order\_before

```cpp
my_bool wsrep_thd_order_before(const MYSQL_THD left, const MYSQL_THD right)
```

Defined in service\_wsrep.h:229

***

### wsrep\_thd\_skip\_locking

```cpp
my_bool wsrep_thd_skip_locking(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:232

***

### wsrep\_thd\_is\_aborting

```cpp
my_bool wsrep_thd_is_aborting(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:234

***

### wsrep\_thd\_in\_rollback

```cpp
my_bool wsrep_thd_in_rollback(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:236

***

### wsrep\_thd\_append\_key

```cpp
int wsrep_thd_append_key(MYSQL_THD thd, const struct wsrep_key * key, int n_keys, enum Wsrep_service_key_type)
```

Defined in service\_wsrep.h:240

***

### wsrep\_thd\_append\_table\_key

```cpp
int wsrep_thd_append_table_key(MYSQL_THD thd, const char * db, const char * table, enum Wsrep_service_key_type)
```

Defined in service\_wsrep.h:245

***

### wsrep\_thd\_is\_local\_transaction

```cpp
my_bool wsrep_thd_is_local_transaction(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:250

***

### wsrep\_get\_sr\_table\_name

```cpp
const char * wsrep_get_sr_table_name()
```

Defined in service\_wsrep.h:254

***

### wsrep\_get\_debug

```cpp
my_bool wsrep_get_debug()
```

Defined in service\_wsrep.h:256

***

### wsrep\_commit\_ordered

```cpp
void wsrep_commit_ordered(MYSQL_THD thd)
```

Defined in service\_wsrep.h:258

***

### wsrep\_OSU\_method\_get

```cpp
ulong wsrep_OSU_method_get(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:260

***

### wsrep\_thd\_has\_ignored\_error

```cpp
my_bool wsrep_thd_has_ignored_error(const MYSQL_THD thd)
```

Defined in service\_wsrep.h:261

***

### wsrep\_thd\_set\_ignored\_error

```cpp
void wsrep_thd_set_ignored_error(MYSQL_THD thd, my_bool val)
```

Defined in service\_wsrep.h:262

***

### wsrep\_report\_bf\_lock\_wait

```cpp
void wsrep_report_bf_lock_wait(const THD * thd, unsigned long long trx_id)
```

Defined in service\_wsrep.h:263

***

### wsrep\_thd\_set\_PA\_unsafe

```cpp
void wsrep_thd_set_PA_unsafe(MYSQL_THD thd)
```

Defined in service\_wsrep.h:266

***

### wsrep\_get\_domain\_id

```cpp
uint32 wsrep_get_domain_id()
```

Defined in service\_wsrep.h:267

***

### my\_base64\_needed\_encoded\_length

```cpp
int my_base64_needed_encoded_length(int length_of_data)
```

Defined in service\_base64.h:57

***

### my\_base64\_encode\_max\_arg\_length

```cpp
int my_base64_encode_max_arg_length(void)
```

Defined in service\_base64.h:60

***

### my\_base64\_needed\_decoded\_length

```cpp
int my_base64_needed_decoded_length(int length_of_encoded_data)
```

Defined in service\_base64.h:63

***

### my\_base64\_decode\_max\_arg\_length

```cpp
int my_base64_decode_max_arg_length()
```

Defined in service\_base64.h:66

***

### my\_base64\_encode

```cpp
int my_base64_encode(const void * src, size_t src_len, char * dst)
```

Defined in service\_base64.h:69

***

### my\_base64\_decode

```cpp
int my_base64_decode(const char * src, size_t src_len, void * dst, const char ** end_ptr, int flags)
```

Defined in service\_base64.h:72

***

### logger\_init\_mutexes

```cpp
void logger_init_mutexes()
```

Defined in service\_logger.h:103

***

### logger\_open

```cpp
LOGGER_HANDLE * logger_open(const char * path, unsigned long long size_limit, unsigned int rotations, size_t buffer_size)
```

Defined in service\_logger.h:104

***

### logger\_close

```cpp
int logger_close(LOGGER_HANDLE * log)
```

Defined in service\_logger.h:107

***

### logger\_vprintf

```cpp
int logger_vprintf(LOGGER_HANDLE * log, const char * fmt, va_list argptr)
```

Defined in service\_logger.h:108

***

### logger\_printf

```cpp
int int logger_printf(LOGGER_HANDLE * log, const char * fmt, ...)
```

Defined in service\_logger.h:110

***

### logger\_write

```cpp
int int int logger_write(LOGGER_HANDLE * log, const void * data, size_t size)
```

Defined in service\_logger.h:112

***

### logger\_rotate

```cpp
int logger_rotate(LOGGER_HANDLE * log)
```

Defined in service\_logger.h:113

***

### logger\_sync

```cpp
int logger_sync(LOGGER_HANDLE * log)
```

Defined in service\_logger.h:114

***

### logger\_resize\_buffer

```cpp
int logger_resize_buffer(LOGGER_HANDLE * log, size_t new_buffer_size)
```

Defined in service\_logger.h:115

***

### logger\_set\_filesize\_limit

```cpp
int logger_set_filesize_limit(LOGGER_HANDLE * log, unsigned long long new_file_limit)
```

Defined in service\_logger.h:116

***

### logger\_set\_rotations

```cpp
int logger_set_rotations(LOGGER_HANDLE * log, unsigned int new_rotations)
```

Defined in service\_logger.h:118

***

### thd\_mdl\_context

```cpp
void * thd_mdl_context(MYSQL_THD thd)
```

Defined in service\_thd\_mdl.h:41

MDL\_context accessor

#### Returns

pointer to thd->mdl\_context

#### Parameters

| Parameter | Type                      | Description         |
| --------- | ------------------------- | ------------------- |
| `thd`     | [`MYSQL_THD`](#mysql_thd) | the current session |

***

### thd\_rnd

```cpp
double thd_rnd(MYSQL_THD thd)
```

Defined in service\_thd\_rnd.h:44

***

### thd\_create\_random\_password

```cpp
void thd_create_random_password(MYSQL_THD thd, char * to, size_t length)
```

Defined in service\_thd\_rnd.h:54

Generate string of printable random characters of requested length.

#### Parameters

| Parameter | Type                      | Description                                                                                          |
| --------- | ------------------------- | ---------------------------------------------------------------------------------------------------- |
| `thd`     | [`MYSQL_THD`](#mysql_thd) | User thread connection handle                                                                        |
| `to`      | `char *`                  | Buffer for generation; must be at least length+1 bytes long; result string is always null-terminated |
| `length`  | `size_t`                  | How many random characters to put in buffer                                                          |

***

### my\_aes\_crypt\_init

```cpp
int my_aes_crypt_init(void * ctx, enum my_aes_mode mode, int flags, const unsigned char * key, unsigned int klen, const unsigned char * iv, unsigned int ivlen)
```

Defined in service\_my\_crypt.h:110

***

### my\_aes\_crypt\_update

```cpp
int my_aes_crypt_update(void * ctx, const unsigned char * src, unsigned int slen, unsigned char * dst, unsigned int * dlen)
```

Defined in service\_my\_crypt.h:113

***

### my\_aes\_crypt\_finish

```cpp
int my_aes_crypt_finish(void * ctx, unsigned char * dst, unsigned int * dlen)
```

Defined in service\_my\_crypt.h:115

***

### my\_aes\_crypt

```cpp
int my_aes_crypt(enum my_aes_mode mode, int flags, const unsigned char * src, unsigned int slen, unsigned char * dst, unsigned int * dlen, const unsigned char * key, unsigned int klen, const unsigned char * iv, unsigned int ivlen)
```

Defined in service\_my\_crypt.h:116

***

### my\_random\_bytes

```cpp
int my_random_bytes(unsigned char * buf, int num)
```

Defined in service\_my\_crypt.h:120

***

### my\_bytes\_to\_key

```cpp
void my_bytes_to_key(const unsigned char * salt, const unsigned char * input, unsigned int input_len, unsigned char * key, unsigned char * iv, enum my_digest digest, unsigned int use_pbkdf2)
```

Defined in service\_my\_crypt.h:121

***

### my\_aes\_get\_size

```cpp
unsigned int my_aes_get_size(enum my_aes_mode mode, unsigned int source_length)
```

Defined in service\_my\_crypt.h:125

***

### my\_aes\_ctx\_size

```cpp
unsigned int my_aes_ctx_size(enum my_aes_mode mode)
```

Defined in service\_my\_crypt.h:126

***

### thd\_wait\_begin

```cpp
void thd_wait_begin(MYSQL_THD thd, int wait_type)
```

Defined in service\_thd\_wait.h:94

***

### thd\_wait\_end

```cpp
void thd_wait_end(MYSQL_THD thd)
```

Defined in service\_thd\_wait.h:95

***

### encryption\_key\_id\_exists

`static` `inline`

```cpp
static inline unsigned int encryption_key_id_exists(unsigned int id)
```

Defined in service\_encryption.h:96

***

### encryption\_key\_version\_exists

`static` `inline`

```cpp
static inline unsigned int encryption_key_version_exists(unsigned int id, unsigned int version)
```

Defined in service\_encryption.h:101

***

### encryption\_crypt

`static` `inline`

```cpp
static inline int encryption_crypt(const unsigned char * src, unsigned int slen, unsigned char * dst, unsigned int * dlen, const unsigned char * key, unsigned int klen, const unsigned char * iv, unsigned int ivlen, int flags, unsigned int key_id, unsigned int key_version)
```

Defined in service\_encryption.h:112

main entrypoint to perform encryption or decryption

#### Invariants

`src` is valid for `slen`

#### Invariants

`dst` is valid for `*dlen`, `*dlen` is initialized

#### Invariants

`src` and `dst` do not overlap

***

### thd\_alloc

```cpp
void * thd_alloc(const MYSQL_THD thd, size_t size)
```

Defined in service\_thd\_alloc.h:102

Allocate memory in the connection's local memory pool

When properly used in place of `my_malloc()`, this can significantly improve concurrency. Don't use this or related functions to allocate large chunks of memory. Use for temporary storage only. The memory will be freed automatically at the end of the statement; no explicit code is required to prevent memory leaks.

**See also**: alloc\_root()

***

### thd\_calloc

```cpp
void * thd_calloc(const MYSQL_THD thd, size_t size)
```

Defined in service\_thd\_alloc.h:106

**See also**: [thd\_alloc()](#thd_alloc)

***

### thd\_strdup

```cpp
char * thd_strdup(const MYSQL_THD thd, const char * str)
```

Defined in service\_thd\_alloc.h:110

**See also**: [thd\_alloc()](#thd_alloc)

***

### thd\_strmake

```cpp
char * thd_strmake(const MYSQL_THD thd, const char * str, size_t size)
```

Defined in service\_thd\_alloc.h:114

**See also**: [thd\_alloc()](#thd_alloc)

***

### thd\_memdup

```cpp
void * thd_memdup(const MYSQL_THD thd, const void * str, size_t size)
```

Defined in service\_thd\_alloc.h:118

**See also**: [thd\_alloc()](#thd_alloc)

***

### thd\_make\_lex\_string

```cpp
MYSQL_CONST_LEX_STRING * thd_make_lex_string(const MYSQL_THD thd, MYSQL_CONST_LEX_STRING * lex_str, const char * str, size_t size, int allocate_lex_string)
```

Defined in service\_thd\_alloc.h:134

Create a LEX\_STRING in this connection's local memory pool

#### Returns

NULL on failure, or pointer to the LEX\_STRING object

**See also**: [thd\_alloc()](#thd_alloc)

#### Parameters

| Parameter             | Type                                                   | Description                                                                     |
| --------------------- | ------------------------------------------------------ | ------------------------------------------------------------------------------- |
| `thd`                 | const [`MYSQL_THD`](#mysql_thd)                        | user thread connection handle                                                   |
| `lex_str`             | [`MYSQL_CONST_LEX_STRING`](#mysql_const_lex_string) \* | pointer to LEX\_STRING object to be initialized                                 |
| `str`                 | `const char *`                                         | initializer to be copied into lex\_str                                          |
| `size`                | `size_t`                                               | length of str, in bytes                                                         |
| `allocate_lex_string` | `int`                                                  | flag: if TRUE, allocate new LEX\_STRING object, instead of using lex\_str value |

***

### my\_snprintf

```cpp
size_t my_snprintf(char * to, size_t n, const char * fmt, ...)
```

Defined in service\_my\_snprintf.h:113

***

### my\_vsnprintf

```cpp
size_t size_t my_vsnprintf(char * to, size_t n, const char * fmt, va_list ap)
```

Defined in service\_my\_snprintf.h:115

***

### thd\_get\_autoinc

```cpp
void thd_get_autoinc(const MYSQL_THD thd, unsigned long * off, unsigned long * inc)
```

Defined in service\_thd\_autoinc.h:44

Return autoincrement system variables

#### Parameters

| Parameter | Type                            | Description                                      |
| --------- | ------------------------------- | ------------------------------------------------ |
| `thd`     | const [`MYSQL_THD`](#mysql_thd) | user thread connection handle                    |
| `off`     | `unsigned long *`               | the value of @SESSION.auto\_increment\_offset    |
| `inc`     | `unsigned long *`               | the value of @SESSION.auto\_increment\_increment |

***

### thd\_log\_warnings

```cpp
int thd_log_warnings(MYSQL_THD thd)
```

Defined in service\_log\_warnings.h:44

MDL\_context accessor

#### Returns

pointer to thd->mdl\_context

#### Parameters

| Parameter | Type                      | Description         |
| --------- | ------------------------- | ------------------- |
| `thd`     | [`MYSQL_THD`](#mysql_thd) | the current session |

***

### thd\_TIME\_to\_gmt\_sec

```cpp
my_time_t thd_TIME_to_gmt_sec(MYSQL_THD thd, const MYSQL_TIME * ltime, unsigned int * errcode)
```

Defined in service\_thd\_timezone.h:67

***

### thd\_gmt\_sec\_to\_TIME

```cpp
void thd_gmt_sec_to_TIME(MYSQL_THD thd, MYSQL_TIME * ltime, my_time_t t)
```

Defined in service\_thd\_timezone.h:68

***

### thd\_TIME\_to\_str

```cpp
void thd_TIME_to_str(MYSQL_THD thd, const MYSQL_TIME * ltime, const char * format, char * buf, unsigned int buf_len)
```

Defined in service\_thd\_timezone.h:69

***

### thd\_key\_create

```cpp
int thd_key_create(MYSQL_THD_KEY_T * key)
```

Defined in service\_thd\_specifics.h:85

create THD specific storage

#### Returns

0 on success else errno is returned

***

### thd\_key\_delete

```cpp
void thd_key_delete(MYSQL_THD_KEY_T * key)
```

Defined in service\_thd\_specifics.h:90

delete THD specific storage

***

### thd\_getspecific

```cpp
void * thd_getspecific(MYSQL_THD thd, MYSQL_THD_KEY_T key)
```

Defined in service\_thd\_specifics.h:99

get/set thd specific storage

* first time this is called from a thread it will return 0
* this call is thread-safe in that different threads may call this simultaneously if operating on different THDs.
* this call acquires no mutexes and is implemented as an array lookup

***

### thd\_setspecific

```cpp
int thd_setspecific(MYSQL_THD thd, MYSQL_THD_KEY_T key, void * value)
```

Defined in service\_thd\_specifics.h:100

***

### thd\_kill\_level

```cpp
enum thd_kill_levels thd_kill_level(const MYSQL_THD)
```

Defined in service\_kill\_statement.h:62

***

### my\_error

```cpp
void my_error(unsigned int nr, unsigned long MyFlags, ...)
```

Defined in service\_my\_print\_error.h:59

***

### my\_printf\_error

```cpp
void my_printf_error(unsigned int my_err, const char * format, unsigned long MyFlags, ...)
```

Defined in service\_my\_print\_error.h:60

***

### my\_printv\_error

```cpp
void void my_printv_error(unsigned int error, const char * format, unsigned long MyFlags, va_list ap)
```

Defined in service\_my\_print\_error.h:63

***

### thd\_progress\_init

```cpp
void thd_progress_init(MYSQL_THD thd, unsigned int max_stage)
```

Defined in service\_progress\_report.h:58

***

### thd\_progress\_report

```cpp
void thd_progress_report(MYSQL_THD thd, unsigned long long progress, unsigned long long max_progress)
```

Defined in service\_progress\_report.h:66

Report progress for long running operations

#### Parameters

| Parameter      | Type                      | Description                       |
| -------------- | ------------------------- | --------------------------------- |
| `thd`          | [`MYSQL_THD`](#mysql_thd) | User thread connection handle     |
| `progress`     | `unsigned long long`      | Where we are now                  |
| `max_progress` | `unsigned long long`      | Progress will continue up to this |

***

### thd\_progress\_next\_stage

```cpp
void thd_progress_next_stage(MYSQL_THD thd)
```

Defined in service\_progress\_report.h:69

***

### thd\_progress\_end

```cpp
void thd_progress_end(MYSQL_THD thd)
```

Defined in service\_progress\_report.h:70

***

### set\_thd\_proc\_info

```cpp
const char * set_thd_proc_info(MYSQL_THD, const char * info, const char * func, const char * file, unsigned int line)
```

Defined in service\_progress\_report.h:71

***

### print\_check\_msg

```cpp
void print_check_msg(MYSQL_THD, const char * db_name, const char * table_name, const char * op, const char * msg_type, const char * message, my_bool print_to_log)
```

Defined in service\_print\_check\_msg.h:37

***

### encryption\_scheme\_encrypt

```cpp
int encryption_scheme_encrypt(const unsigned char * src, unsigned int slen, unsigned char * dst, unsigned int * dlen, struct st_encryption_scheme * scheme, unsigned int key_version, unsigned int i32_1, unsigned int i32_2, unsigned long long i64)
```

Defined in service\_encryption\_scheme.h:114

***

### encryption\_scheme\_decrypt

```cpp
int encryption_scheme_decrypt(const unsigned char * src, unsigned int slen, unsigned char * dst, unsigned int * dlen, struct st_encryption_scheme * scheme, unsigned int key_version, unsigned int i32_1, unsigned int i32_2, unsigned long long i64)
```

Defined in service\_encryption\_scheme.h:119

***

### thd\_get\_error\_message

```cpp
const char * thd_get_error_message(const MYSQL_THD thd)
```

Defined in service\_thd\_error\_context.h:61

Return error message

#### Returns

error text

#### Parameters

| Parameter | Type                            | Description                   |
| --------- | ------------------------------- | ----------------------------- |
| `thd`     | const [`MYSQL_THD`](#mysql_thd) | user thread connection handle |

***

### thd\_get\_error\_number

```cpp
unsigned int thd_get_error_number(const MYSQL_THD thd)
```

Defined in service\_thd\_error\_context.h:67

Return error number

#### Returns

error number

#### Parameters

| Parameter | Type                            | Description                   |
| --------- | ------------------------------- | ----------------------------- |
| `thd`     | const [`MYSQL_THD`](#mysql_thd) | user thread connection handle |

***

### thd\_get\_error\_row

```cpp
unsigned long thd_get_error_row(const MYSQL_THD thd)
```

Defined in service\_thd\_error\_context.h:73

Return the current row number (i.e. in a multiple INSERT statement)

#### Returns

row number

#### Parameters

| Parameter | Type                            | Description                   |
| --------- | ------------------------------- | ----------------------------- |
| `thd`     | const [`MYSQL_THD`](#mysql_thd) | user thread connection handle |

***

### thd\_inc\_error\_row

```cpp
void thd_inc_error_row(MYSQL_THD thd)
```

Defined in service\_thd\_error\_context.h:78

Increment the current row number

#### Parameters

| Parameter | Type                      | Description                   |
| --------- | ------------------------- | ----------------------------- |
| `thd`     | [`MYSQL_THD`](#mysql_thd) | user thread connection handle |

***

### thd\_get\_error\_context\_description

```cpp
char * thd_get_error_context_description(MYSQL_THD thd, char * buffer, unsigned int length, unsigned int max_query_length)
```

Defined in service\_thd\_error\_context.h:83

Return a text description of a thread, its security context (user,host) and the current query.

## Variables

***

### PSI\_server

```cpp
MYSQL_PLUGIN_IMPORT PSI * PSI_server
```

Type: MYSQL\_PLUGIN\_IMPORT [`PSI`](#psi) \*

Defined in psi/psi.h:3019

***

### my\_md5\_service

```cpp
struct my_md5_service_st * my_md5_service
```

Type: struct [`my_md5_service_st`](#my_md5_service_st) \*

Defined in service\_md5.h:41

***

### sql\_service

```cpp
struct sql_service_st * sql_service
```

Type: struct [`sql_service_st`](#sql_service_st) \*

Defined in service\_sql.h:77

***

### thd\_service

```cpp
struct thd_service_st * thd_service
```

Type: struct [`thd_service_st`](#thd_service_st) \*

Defined in service\_thd.h:29

***

### json\_service

```cpp
struct json_service_st * json_service
```

Type: struct [`json_service_st`](#json_service_st) \*

Defined in service\_json.h:81

***

### my\_sha1\_service

```cpp
struct my_sha1_service_st * my_sha1_service
```

Type: struct [`my_sha1_service_st`](#my_sha1_service_st) \*

Defined in service\_sha1.h:41

***

### my\_sha2\_service

```cpp
struct my_sha2_service_st * my_sha2_service
```

Type: struct [`my_sha2_service_st`](#my_sha2_service_st) \*

Defined in service\_sha2.h:60

***

### wsrep\_service

```cpp
struct wsrep_service_st * wsrep_service
```

Type: struct [`wsrep_service_st`](#wsrep_service_st) \*

Defined in service\_wsrep.h:105

***

### wsrep\_debug

```cpp
ulong wsrep_debug
```

Defined in service\_wsrep.h:159

***

### wsrep\_log\_conflicts

```cpp
my_bool wsrep_log_conflicts
```

Type: [`my_bool`](#my_bool)

Defined in service\_wsrep.h:160

***

### wsrep\_certify\_nonPK

```cpp
my_bool wsrep_certify_nonPK
```

Type: [`my_bool`](#my_bool)

Defined in service\_wsrep.h:161

***

### wsrep\_load\_data\_splitting

```cpp
my_bool wsrep_load_data_splitting
```

Type: [`my_bool`](#my_bool)

Defined in service\_wsrep.h:162

***

### wsrep\_drupal\_282555\_workaround

```cpp
my_bool wsrep_drupal_282555_workaround
```

Type: [`my_bool`](#my_bool)

Defined in service\_wsrep.h:163

***

### wsrep\_recovery

```cpp
my_bool wsrep_recovery
```

Type: [`my_bool`](#my_bool)

Defined in service\_wsrep.h:164

***

### wsrep\_protocol\_version

```cpp
long wsrep_protocol_version
```

Defined in service\_wsrep.h:165

***

### wsrep\_sr\_table\_name\_full

```cpp
const char * wsrep_sr_table_name_full
```

Defined in service\_wsrep.h:252

***

### base64\_service

```cpp
struct base64_service_st * base64_service
```

Type: struct [`base64_service_st`](#base64_service_st) \*

Defined in service\_base64.h:43

***

### logger\_service

```cpp
struct logger_service_st * logger_service
```

Type: struct [`logger_service_st`](#logger_service_st) \*

Defined in service\_logger.h:80

***

### thd\_mdl\_service

```cpp
struct thd_mdl_service_st * thd_mdl_service
```

Type: struct [`thd_mdl_service_st`](#thd_mdl_service_st) \*

Defined in service\_thd\_mdl.h:31

***

### thd\_rnd\_service

```cpp
struct thd_rnd_service_st * thd_rnd_service
```

Type: struct [`thd_rnd_service_st`](#thd_rnd_service_st) \*

Defined in service\_thd\_rnd.h:37

***

### my\_crypt\_service

```cpp
struct my_crypt_service_st * my_crypt_service
```

Type: struct [`my_crypt_service_st`](#my_crypt_service_st) \*

Defined in service\_my\_crypt.h:80

***

### thd\_wait\_service

```cpp
struct thd_wait_service_st * thd_wait_service
```

Type: struct [`thd_wait_service_st`](#thd_wait_service_st) \*

Defined in service\_thd\_wait.h:84

***

### encryption\_handler

```cpp
struct encryption_service_st encryption_handler
```

Type: struct [`encryption_service_st`](#encryption_service_st)

Defined in service\_encryption.h:85

***

### thd\_alloc\_service

```cpp
struct thd_alloc_service_st * thd_alloc_service
```

Type: struct [`thd_alloc_service_st`](#thd_alloc_service_st) \*

Defined in service\_thd\_alloc.h:68

***

### debug\_sync\_C\_callback\_ptr

```cpp
void(* debug_sync_C_callback_ptr)(MYSQL_THD, const char *, size_t)
```

Defined in service\_debug\_sync.h:333

***

### my\_snprintf\_service

```cpp
struct my_snprintf_service_st * my_snprintf_service
```

Type: struct [`my_snprintf_service_st`](#my_snprintf_service_st) \*

Defined in service\_my\_snprintf.h:104

***

### thd\_autoinc\_service

```cpp
struct thd_autoinc_service_st * thd_autoinc_service
```

Type: struct [`thd_autoinc_service_st`](#thd_autoinc_service_st) \*

Defined in service\_thd\_autoinc.h:32

***

### thd\_log\_warnings\_service

```cpp
struct thd_log_warnings_service_st * thd_log_warnings_service
```

Type: struct [`thd_log_warnings_service_st`](#thd_log_warnings_service_st) \*

Defined in service\_log\_warnings.h:34

***

### thd\_timezone\_service

```cpp
struct thd_timezone_service_st * thd_timezone_service
```

Type: struct [`thd_timezone_service_st`](#thd_timezone_service_st) \*

Defined in service\_thd\_timezone.h:52

***

### thd\_specifics\_service

```cpp
struct thd_specifics_service_st * thd_specifics_service
```

Type: struct [`thd_specifics_service_st`](#thd_specifics_service_st) \*

Defined in service\_thd\_specifics.h:67

***

### thd\_kill\_statement\_service

```cpp
struct kill_statement_service_st * thd_kill_statement_service
```

Type: struct [`kill_statement_service_st`](#kill_statement_service_st) \*

Defined in service\_kill\_statement.h:50

***

### my\_print\_error\_service

```cpp
struct my_print_error_service_st * my_print_error_service
```

Type: struct [`my_print_error_service_st`](#my_print_error_service_st) \*

Defined in service\_my\_print\_error.h:50

***

### progress\_report\_service

```cpp
struct progress_report_service_st * progress_report_service
```

Type: struct [`progress_report_service_st`](#progress_report_service_st) \*

Defined in service\_progress\_report.h:46

***

### print\_check\_msg\_service

```cpp
struct print_check_msg_service_st * print_check_msg_service
```

Type: struct [`print_check_msg_service_st`](#print_check_msg_service_st) \*

Defined in service\_print\_check\_msg.h:32

***

### encryption\_scheme\_service

```cpp
struct encryption_scheme_service_st * encryption_scheme_service
```

Type: struct [`encryption_scheme_service_st`](#encryption_scheme_service_st) \*

Defined in service\_encryption\_scheme.h:105

***

### thd\_error\_context\_service

```cpp
struct thd_error_context_service_st * thd_error_context_service
```

Type: struct [`thd_error_context_service_st`](#thd_error_context_service_st) \*

Defined in service\_thd\_error\_context.h:39

## Class Definitions

### opaque\_THD

```cpp
#include <psi.h>
```

```cpp
struct opaque_THD
```

Defined in psi/psi.h:95

### st\_mysql\_xid

```cpp
#include <plugin.h>
```

```cpp
struct st_mysql_xid
```

Defined in plugin.h:71

struct [st\_mysql\_xid](#st_mysql_xid) is binary compatible with the XID structure as in the X/Open CAE Specification, Distributed Transaction Processing: The XA Specification, X/Open Company Ltd., 1991. <http://www.opengroup.org/bookstore/catalog/c193.htm>

**See also**: XID in sql/handler.h

### st\_mysql\_auth

```cpp
#include <plugin_auth.h>
```

```cpp
struct st_mysql_auth
```

Defined in plugin\_auth.h:119

Server authentication plugin descriptor

### st\_plugin\_vio

```cpp
#include <plugin_auth_common.h>
```

```cpp
struct st_plugin_vio
```

Defined in plugin\_auth\_common.h:107

Provides plugin access to communication channel

### sql\_service\_st

```cpp
#include <service_sql.h>
```

```cpp
struct sql_service_st
```

Defined in service\_sql.h:49

### st\_mysql\_audit

```cpp
#include <plugin_audit.h>
```

```cpp
struct st_mysql_audit
```

Defined in plugin\_audit.h:183

### st\_mysql\_value

```cpp
#include <plugin.h>
```

```cpp
struct st_mysql_value
```

Defined in plugin.h:678

### thd\_service\_st

```cpp
#include <service_thd.h>
```

```cpp
struct thd_service_st
```

Defined in service\_thd.h:27

### json\_service\_st

```cpp
#include <service_json.h>
```

```cpp
struct json_service_st
```

Defined in service\_json.h:64

### st\_maria\_plugin

```cpp
#include <plugin.h>
```

```cpp
struct st_maria_plugin
```

Defined in plugin.h:567

MariaDB extension for plugins declaration structure.

It also copies current MySQL plugin fields to have more independency in plugins extension

### st\_mysql\_daemon

```cpp
#include <plugin.h>
```

```cpp
struct st_mysql_daemon
```

Defined in plugin.h:607

### st\_mysql\_plugin

```cpp
#include <plugin.h>
```

```cpp
struct st_mysql_plugin
```

Defined in plugin.h:537

Plugin description structure.

### Mysql\_replication

```cpp
#include <plugin.h>
```

```cpp
struct Mysql_replication
```

Defined in plugin.h:660

Replication plugin descriptor

### wsrep\_service\_st

```cpp
#include <service_wsrep.h>
```

```cpp
struct wsrep_service_st
```

Defined in service\_wsrep.h:56

### base64\_service\_st

```cpp
#include <service_base64.h>
```

```cpp
struct base64_service_st
```

Defined in service\_base64.h:35

### logger\_service\_st

```cpp
#include <service_logger.h>
```

```cpp
struct logger_service_st
```

Defined in service\_logger.h:63

### mysql\_event\_table

```cpp
#include <plugin_audit.h>
```

```cpp
struct mysql_event_table
```

Defined in plugin\_audit.h:142

### st\_mysql\_ftparser

```cpp
#include <plugin_ftparser.h>
```

```cpp
struct st_mysql_ftparser
```

Defined in plugin\_ftparser.h:208

### my\_md5\_service\_st

```cpp
#include <service_md5.h>
```

```cpp
struct my_md5_service_st
```

Defined in service\_md5.h:34

### st\_mysql\_show\_var

```cpp
#include <plugin.h>
```

```cpp
struct st_mysql_show_var
```

Defined in plugin.h:206

### my\_sha1\_service\_st

```cpp
#include <service_sha1.h>
```

```cpp
struct my_sha1_service_st
```

Defined in service\_sha1.h:34

### my\_sha2\_service\_st

```cpp
#include <service_sha2.h>
```

```cpp
struct my_sha2_service_st
```

Defined in service\_sha2.h:32

### mysql\_event\_general

```cpp
#include <plugin_audit.h>
```

```cpp
struct mysql_event_general
```

Defined in plugin\_audit.h:53

### st\_plugin\_vio\_info

```cpp
#include <plugin_auth_common.h>
```

```cpp
struct st_plugin_vio_info
```

Defined in plugin\_auth\_common.h:93

### thd\_mdl\_service\_st

```cpp
#include <service_thd_mdl.h>
```

```cpp
struct thd_mdl_service_st
```

Defined in service\_thd\_mdl.h:29

### thd\_rnd\_service\_st

```cpp
#include <service_thd_rnd.h>
```

```cpp
struct thd_rnd_service_st
```

Defined in service\_thd\_rnd.h:34

### my\_crypt\_service\_st

```cpp
#include <service_my_crypt.h>
```

```cpp
struct my_crypt_service_st
```

Defined in service\_my\_crypt.h:63

### st\_encryption\_scheme

```cpp
#include <service_encryption_scheme.h>
```

```cpp
struct st_encryption_scheme
```

Defined in service\_encryption\_scheme.h:82

### st\_mysql\_lex\_string

```cpp
#include <service_thd_alloc.h>
```

```cpp
struct st_mysql_lex_string
```

Defined in service\_thd\_alloc.h:45

### thd\_wait\_service\_st

```cpp
#include <service_thd_wait.h>
```

```cpp
struct thd_wait_service_st
```

Defined in service\_thd\_wait.h:81

### encryption\_service\_st

```cpp
#include <service_encryption.h>
```

```cpp
struct encryption_service_st
```

Defined in service\_encryption.h:57

### st\_mariadb\_encryption

```cpp
#include <plugin_encryption.h>
```

```cpp
struct st_mariadb_encryption
```

Defined in plugin\_encryption.h:39

Encryption plugin descriptor

### thd\_alloc\_service\_st

```cpp
#include <service_thd_alloc.h>
```

```cpp
struct thd_alloc_service_st
```

Defined in service\_thd\_alloc.h:59

### mysql\_event\_connection

```cpp
#include <plugin_audit.h>
```

```cpp
struct mysql_event_connection
```

Defined in plugin\_audit.h:97

### my\_snprintf\_service\_st

```cpp
#include <service_my_snprintf.h>
```

```cpp
struct my_snprintf_service_st
```

Defined in service\_my\_snprintf.h:99

### st\_mysql\_client\_plugin

```cpp
#include <client_plugin.h>
```

```cpp
struct st_mysql_client_plugin
```

Defined in client\_plugin.h:85

### thd\_autoinc\_service\_st

```cpp
#include <service_thd_autoinc.h>
```

```cpp
struct thd_autoinc_service_st
```

Defined in service\_thd\_autoinc.h:29

### st\_mysql\_ftparser\_param

```cpp
#include <plugin_ftparser.h>
```

```cpp
struct st_mysql_ftparser_param
```

Defined in plugin\_ftparser.h:184

### st\_mysql\_storage\_engine

```cpp
#include <plugin.h>
```

```cpp
struct st_mysql_storage_engine
```

Defined in plugin.h:644

### thd\_timezone\_service\_st

```cpp
#include <service_thd_timezone.h>
```

```cpp
struct thd_timezone_service_st
```

Defined in service\_thd\_timezone.h:48

### st\_encryption\_scheme\_key

```cpp
#include <service_encryption_scheme.h>
```

```cpp
struct st_encryption_scheme_key
```

Defined in service\_encryption\_scheme.h:77

### thd\_specifics\_service\_st

```cpp
#include <service_thd_specifics.h>
```

```cpp
struct thd_specifics_service_st
```

Defined in service\_thd\_specifics.h:62

### kill\_statement\_service\_st

```cpp
#include <service_kill_statement.h>
```

```cpp
struct kill_statement_service_st
```

Defined in service\_kill\_statement.h:48

### my\_print\_error\_service\_st

```cpp
#include <service_my_print_error.h>
```

```cpp
struct my_print_error_service_st
```

Defined in service\_my\_print\_error.h:42

### progress\_report\_service\_st

```cpp
#include <service_progress_report.h>
```

```cpp
struct progress_report_service_st
```

Defined in service\_progress\_report.h:35

### st\_mysql\_const\_lex\_string

```cpp
#include <service_thd_alloc.h>
```

```cpp
struct st_mysql_const_lex_string
```

Defined in service\_thd\_alloc.h:38

### st\_mysql\_server\_auth\_info

```cpp
#include <plugin_auth.h>
```

```cpp
struct st_mysql_server_auth_info
```

Defined in plugin\_auth.h:48

Provides server plugin access to authentication information

### print\_check\_msg\_service\_st

```cpp
#include <service_print_check_msg.h>
```

```cpp
struct print_check_msg_service_st
```

Defined in service\_print\_check\_msg.h:28

### st\_mysql\_information\_schema

```cpp
#include <plugin.h>
```

```cpp
struct st_mysql_information_schema
```

Defined in plugin.h:625

### encryption\_scheme\_service\_st

```cpp
#include <service_encryption_scheme.h>
```

```cpp
struct encryption_scheme_service_st
```

Defined in service\_encryption\_scheme.h:92

### thd\_log\_warnings\_service\_st

```cpp
#include <service_log_warnings.h>
```

```cpp
struct thd_log_warnings_service_st
```

Defined in service\_log\_warnings.h:32

### thd\_error\_context\_service\_st

```cpp
#include <service_thd_error_context.h>
```

```cpp
struct thd_error_context_service_st
```

Defined in service\_thd\_error\_context.h:30

### st\_mariadb\_password\_validation

```cpp
#include <plugin_password_validation.h>
```

```cpp
struct st_mariadb_password_validation
```

Defined in plugin\_password\_validation.h:38

Password validation plugin descriptor

### st\_mysql\_ftparser\_boolean\_info

```cpp
#include <plugin_ftparser.h>
```

```cpp
struct st_mysql_ftparser_boolean_info
```

Defined in plugin\_ftparser.h:120

### st\_mysql\_client\_plugin\_AUTHENTICATION

```cpp
#include <client_plugin.h>
```

```cpp
struct st_mysql_client_plugin_AUTHENTICATION
```

Defined in client\_plugin.h:95

Generated by [Moxygen](https://0state.com/moxygen)
