MySQL 9.0.0
Source Code Documentation
io_plugin.cc File Reference
#include "io_plugin.h"
#include <algorithm>
#include <array>
#include <map>
#include <memory>
#include <stdexcept>
#include <string>
#include <thread>
#include "my_thread.h"
#include "mysql/harness/config_option.h"
#include "mysql/harness/config_parser.h"
#include "mysql/harness/dynamic_config.h"
#include "mysql/harness/loader.h"
#include "mysql/harness/logging/logging.h"
#include "mysql/harness/net_ts/io_context.h"
#include "mysql/harness/plugin.h"
#include "mysql/harness/plugin_config.h"
#include "mysql/harness/section_config_exposer.h"
#include "mysql/harness/utility/string.h"
#include "mysqlrouter/io_component.h"
#include "mysqlrouter/io_export.h"
#include "mysqlrouter/io_thread.h"

Classes

class  IoPluginConfig
 
class  anonymous_namespace{io_plugin.cc}::IoConfigExposer
 

Namespaces

namespace  anonymous_namespace{io_plugin.cc}
 

Macros

#define MYSQL_ROUTER_LOG_DOMAIN   "io"
 
#define GET_OPTION_CHECKED(option, section, name, value)
 

Typedefs

using StringOption = mysql_harness::StringOption
 
template<class T >
using IntOption = mysql_harness::IntOption< T >
 

Functions

static void init (mysql_harness::PluginFuncEnv *env)
 
static void run (mysql_harness::PluginFuncEnv *)
 
static void deinit (mysql_harness::PluginFuncEnv *)
 
static void expose_configuration (mysql_harness::PluginFuncEnv *env, const char *, bool initial)
 

Variables

static constexpr const char kSectionName [] {"io"}
 io plugin. More...
 
static constexpr const size_t kMaxThreads {1024}
 
static constexpr std::array supported_options
 
static constexpr std::array required
 
mysql_harness::Plugin IO_EXPORT harness_plugin_io
 

Macro Definition Documentation

◆ GET_OPTION_CHECKED

#define GET_OPTION_CHECKED (   option,
  section,
  name,
  value 
)
Value:
option = get_option(section, name, value);
static constexpr std::array supported_options
Definition: io_plugin.cc:78
constexpr bool str_in_collection(const T &t, const std::string_view &k)
Definition: string.h:157
case opt name
Definition: sslopt-case.h:29

◆ MYSQL_ROUTER_LOG_DOMAIN

#define MYSQL_ROUTER_LOG_DOMAIN   "io"

Typedef Documentation

◆ IntOption

template<class T >
using IntOption = mysql_harness::IntOption<T>

◆ StringOption

Function Documentation

◆ deinit()

static void deinit ( mysql_harness::PluginFuncEnv )
static

◆ expose_configuration()

static void expose_configuration ( mysql_harness::PluginFuncEnv env,
const char *  ,
bool  initial 
)
static

◆ init()

static void init ( mysql_harness::PluginFuncEnv env)
static

◆ run()

static void run ( mysql_harness::PluginFuncEnv )
static

Variable Documentation

◆ harness_plugin_io

mysql_harness::Plugin IO_EXPORT harness_plugin_io
Initial value:
= {
mysql_harness::PLUGIN_ABI_VERSION,
mysql_harness::ARCHITECTURE_DESCRIPTOR,
"IO",
VERSION_NUMBER(0, 0, 1),
required.size(),
required.data(),
0,
nullptr,
init,
run,
nullptr,
false,
}
static constexpr std::array required
Definition: io_plugin.cc:210
static void expose_configuration(mysql_harness::PluginFuncEnv *env, const char *, bool initial)
Definition: io_plugin.cc:238
static void init(mysql_harness::PluginFuncEnv *env)
Definition: io_plugin.cc:117
static void run(mysql_harness::PluginFuncEnv *)
Definition: io_plugin.cc:199
static void deinit(mysql_harness::PluginFuncEnv *)
Definition: io_plugin.cc:205

◆ kMaxThreads

constexpr const size_t kMaxThreads {1024}
staticconstexpr

◆ kSectionName

constexpr const char kSectionName[] {"io"}
staticconstexpr

io plugin.

manages the configuration of the io-threads and the io-backends.

◆ required

constexpr std::array required
staticconstexpr
Initial value:
{
"logger",
}

◆ supported_options

constexpr std::array supported_options
staticconstexpr
Initial value:
{
"backend",
"threads",
}