Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Plugin Declaration

Plugin API reference: Plugin Declaration. Generated from the MariaDB server headers by doxygen and moxygen.

Plugin API

How to declare a plugin to the server.

Macros for beginning and ending plugin declarations. Between maria_declare_plugin and maria_declare_plugin_end there should be a st_maria_plugin struct for each plugin to be declared.

Groups

Name
Description

The allowable licenses for plugins

The allowable code maturity levels for plugins

Constants for plugin flags.

Declarations for server variables and command line options.

Classes

Name
Description

Plugin description structure.

MariaDB extension for plugins declaration structure.

Macros

Name
Description

MYSQL_DLLEXPORT

Defined in plugin.h:45

Declaration macros for MySQL plugins.

On Windows, exports from DLL need to be declared Also, plugin needs to be declared as extern "C" because MSVC unlike other compilers, uses C++ mangling for variables not only for functions.


MYSQL_PLUGIN_EXPORT

Defined in plugin.h:58

Implementation independent macro for MySQL plugins.


MYSQL_PLUGIN_INTERFACE_VERSION

Defined in plugin.h:115

MySQL plugin interface version


MARIA_PLUGIN_INTERFACE_VERSION

Defined in plugin.h:118

MariaDB plugin interface version


__MYSQL_DECLARE_PLUGIN

Defined in plugin.h:207


MARIA_DECLARE_PLUGIN__

Defined in plugin.h:215


mysql_declare_plugin

Defined in plugin.h:225


maria_declare_plugin

Defined in plugin.h:231


mysql_declare_plugin_end

Defined in plugin.h:237


maria_declare_plugin_end

Defined in plugin.h:238

Typedefs

Return
Name
Description

void *

Opaque type for a plugin handle.


MYSQL_PLUGIN

Defined in plugin.h:78

Opaque type for a plugin handle.

Class Definitions

st_mysql_plugin

Defined in plugin.h:715

Plugin description structure.

Public Attributes

Return
Name
Description

int

the plugin type (a MYSQL_XXX_PLUGIN value)

void *

pointer to type-specific plugin descriptor

const char *

plugin name

const char *

plugin author (for I_S.PLUGINS)

const char *

general descriptive text (for I_S.PLUGINS)

int

the plugin license (PLUGIN_LICENSE_XXX)

int(*

The function to invoke when plugin is loaded. Plugin initialisation done here should defer any ALTER TABLE queries to after the ddl recovery is done, in the signal_ddl_recovery_done() callback called by ha_signal_ddl_recovery_done().

int(*

the function to invoke when plugin is unloaded

unsigned int

plugin version (for I_S.PLUGINS)

struct st_mysql_sys_var **

void *

reserved for dependency checking

unsigned long

flags for plugin


type

Defined in plugin.h:717

the plugin type (a MYSQL_XXX_PLUGIN value)


info

Defined in plugin.h:718

pointer to type-specific plugin descriptor


name

Defined in plugin.h:719

plugin name


author

Defined in plugin.h:720

plugin author (for I_S.PLUGINS)


descr

Defined in plugin.h:721

general descriptive text (for I_S.PLUGINS)


license

Defined in plugin.h:722

the plugin license (PLUGIN_LICENSE_XXX)


init

Defined in plugin.h:729

The function to invoke when plugin is loaded. Plugin initialisation done here should defer any ALTER TABLE queries to after the ddl recovery is done, in the signal_ddl_recovery_done() callback called by ha_signal_ddl_recovery_done().


deinit

Defined in plugin.h:730

the function to invoke when plugin is unloaded


version

Defined in plugin.h:731

plugin version (for I_S.PLUGINS)


status_vars

Type: struct st_mysql_show_var *

Defined in plugin.h:732


system_vars

Defined in plugin.h:733


__reserved1

Defined in plugin.h:734

reserved for dependency checking


flags

Defined in plugin.h:735

flags for plugin

st_maria_plugin

Defined in plugin.h:746

MariaDB extension for plugins declaration structure.

It also copies current MySQL plugin fields to have more independency in plugins extension

Public Attributes

Return
Name
Description

int

the plugin type (a MYSQL_XXX_PLUGIN value)

void *

pointer to type-specific plugin descriptor

const char *

plugin name

const char *

plugin author (for SHOW PLUGINS)

const char *

general descriptive text (for SHOW PLUGINS )

int

the plugin license (PLUGIN_LICENSE_XXX)

int(*

The function to invoke when plugin is loaded. Plugin initialisation done here should defer any ALTER TABLE queries to after the ddl recovery is done, in the signal_ddl_recovery_done() callback called by ha_signal_ddl_recovery_done().

int(*

the function to invoke when plugin is unloaded

unsigned int

plugin version (for SHOW PLUGINS)

struct st_mysql_sys_var **

const char *

plugin version string

unsigned int

MariaDB_PLUGIN_MATURITY_XXX


type

Defined in plugin.h:748

the plugin type (a MYSQL_XXX_PLUGIN value)


info

Defined in plugin.h:749

pointer to type-specific plugin descriptor


name

Defined in plugin.h:750

plugin name


author

Defined in plugin.h:751

plugin author (for SHOW PLUGINS)


descr

Defined in plugin.h:752

general descriptive text (for SHOW PLUGINS )


license

Defined in plugin.h:753

the plugin license (PLUGIN_LICENSE_XXX)


init

Defined in plugin.h:760

The function to invoke when plugin is loaded. Plugin initialisation done here should defer any ALTER TABLE queries to after the ddl recovery is done, in the signal_ddl_recovery_done() callback called by ha_signal_ddl_recovery_done().


deinit

Defined in plugin.h:761

the function to invoke when plugin is unloaded


version

Defined in plugin.h:762

plugin version (for SHOW PLUGINS)


status_vars

Type: struct st_mysql_show_var *

Defined in plugin.h:763


system_vars

Defined in plugin.h:764


version_info

Defined in plugin.h:765

plugin version string


maturity

Defined in plugin.h:766

MariaDB_PLUGIN_MATURITY_XXX

This page is licensed: GPLv2

Last updated

Was this helpful?