MySQL 9.1.0
Source Code Documentation
rest_routing_plugin.cc File Reference

Classes

class  RestRoutingPluginConfig
 
class  anonymous_namespace{rest_routing_plugin.cc}::RestRoutingConfigExposer
 

Namespaces

namespace  anonymous_namespace{rest_routing_plugin.cc}
 

Macros

#define GET_OPTION_CHECKED(option, section, name, value)
 

Typedefs

using StringOption = mysql_harness::StringOption
 
using JsonPointer = RestApiComponent::JsonPointer
 
using JsonValue = RestApiComponent::JsonValue
 

Functions

static void init (mysql_harness::PluginFuncEnv *env)
 
static JsonPointer::Token make_json_pointer_token (std::string_view token)
 
std::string json_pointer_stringfy (const JsonPointer &ptr)
 
static void spec_adder (RestApiComponent::JsonDocument &spec_doc)
 
static void start (mysql_harness::PluginFuncEnv *env)
 
static void expose_configuration (mysql_harness::PluginFuncEnv *env, const char *, bool initial)
 

Variables

static const char kSectionName [] {"rest_routing"}
 
static const char kRequireRealm [] {"require_realm"}
 
std::string require_realm_routing
 
static const std::array routing_status_path_tokens
 
static const std::array routing_status_def_tokens
 
static const std::array route_name_param_tokens
 
static const std::array routes_list_def_tokens
 
static const std::array routes_destination_list_def_tokens
 
static const std::array routes_destination_summary_def_tokens
 
static const std::array routes_blockedhost_list_def_tokens
 
static const std::array routes_blockedhost_summary_def_tokens
 
static const std::array routes_connection_list_def_tokens
 
static const std::array routes_connection_summary_def_tokens
 
static const std::array routes_summary_def_tokens
 
static const std::array routes_config_def_tokens
 
static const std::array routes_status_def_tokens
 
static const std::array routes_health_def_tokens
 
static const std::array routes_status_path_tokens
 
static const std::array routes_config_path_tokens
 
static const std::array routes_health_path_tokens
 
static const std::array routes_connection_list_path_tokens
 
static const std::array routes_blockedhost_list_path_tokens
 
static const std::array routes_destination_list_path_tokens
 
static const std::array routes_list_path_tokens
 
static const std::array tags_append_tokens
 
static constexpr std::array required
 
mysql_harness::Plugin REST_ROUTING_EXPORT harness_plugin_rest_routing
 

Macro Definition Documentation

◆ GET_OPTION_CHECKED

#define GET_OPTION_CHECKED (   option,
  section,
  name,
  value 
)
Value:
static_assert( \
option = get_option(section, name, value);
constexpr bool str_in_collection(const T &t, const std::string_view &k)
Definition: string.h:94
case opt name
Definition: sslopt-case.h:29
static constexpr std::array rest_plugin_supported_options
Definition: supported_rest_options.h:31

Typedef Documentation

◆ JsonPointer

◆ JsonValue

◆ StringOption

Function Documentation

◆ expose_configuration()

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

◆ init()

static void init ( mysql_harness::PluginFuncEnv env)
static

◆ json_pointer_stringfy()

std::string json_pointer_stringfy ( const JsonPointer ptr)

◆ make_json_pointer_token()

static JsonPointer::Token make_json_pointer_token ( std::string_view  token)
static

◆ spec_adder()

static void spec_adder ( RestApiComponent::JsonDocument spec_doc)
static

◆ start()

static void start ( mysql_harness::PluginFuncEnv env)
static

Variable Documentation

◆ harness_plugin_rest_routing

mysql_harness::Plugin REST_ROUTING_EXPORT harness_plugin_rest_routing
Initial value:
= {
mysql_harness::PLUGIN_ABI_VERSION,
mysql_harness::ARCHITECTURE_DESCRIPTOR,
"REST_ROUTING",
VERSION_NUMBER(0, 0, 1),
required.size(),
required.data(),
0,
nullptr,
init,
nullptr,
nullptr,
true,
}
static constexpr std::array required
Definition: rest_routing_plugin.cc:1249
static void expose_configuration(mysql_harness::PluginFuncEnv *env, const char *, bool initial)
Definition: rest_routing_plugin.cc:1279
static void init(mysql_harness::PluginFuncEnv *env)
Definition: rest_routing_plugin.cc:92
static void start(mysql_harness::PluginFuncEnv *env)
Definition: rest_routing_plugin.cc:1208

◆ kRequireRealm

const char kRequireRealm[] {"require_realm"}
static

◆ kSectionName

const char kSectionName[] {"rest_routing"}
static

◆ require_realm_routing

std::string require_realm_routing

◆ required

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

◆ route_name_param_tokens

const std::array route_name_param_tokens
static
Initial value:
{
make_json_pointer_token("parameters"),
make_json_pointer_token("routeNameParam"),
}
static JsonPointer::Token make_json_pointer_token(std::string_view token)
Definition: rest_routing_plugin.cc:157

◆ routes_blockedhost_list_def_tokens

const std::array routes_blockedhost_list_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteBlockedHostList"),
}

◆ routes_blockedhost_list_path_tokens

const std::array routes_blockedhost_list_path_tokens
static
Initial value:
{
make_json_pointer_token("/routes/{routeName}/blockedHosts"),
}

◆ routes_blockedhost_summary_def_tokens

const std::array routes_blockedhost_summary_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteBlockedHostSummary"),
}

◆ routes_config_def_tokens

const std::array routes_config_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteConfig"),
}

◆ routes_config_path_tokens

const std::array routes_config_path_tokens
static
Initial value:
{
make_json_pointer_token("/routes/{routeName}/config"),
}

◆ routes_connection_list_def_tokens

const std::array routes_connection_list_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteConnectionsList"),
}

◆ routes_connection_list_path_tokens

const std::array routes_connection_list_path_tokens
static
Initial value:
{
make_json_pointer_token("/routes/{routeName}/connections"),
}

◆ routes_connection_summary_def_tokens

const std::array routes_connection_summary_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteConnectionsSummary"),
}

◆ routes_destination_list_def_tokens

const std::array routes_destination_list_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteDestinationList"),
}

◆ routes_destination_list_path_tokens

const std::array routes_destination_list_path_tokens
static
Initial value:
{
make_json_pointer_token("/routes/{routeName}/destinations"),
}

◆ routes_destination_summary_def_tokens

const std::array routes_destination_summary_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteDestinationSummary"),
}

◆ routes_health_def_tokens

const std::array routes_health_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteHealth"),
}

◆ routes_health_path_tokens

const std::array routes_health_path_tokens
static
Initial value:
{
make_json_pointer_token("/routes/{routeName}/health"),
}

◆ routes_list_def_tokens

const std::array routes_list_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
}

◆ routes_list_path_tokens

const std::array routes_list_path_tokens
static
Initial value:

◆ routes_status_def_tokens

const std::array routes_status_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteStatus"),
}

◆ routes_status_path_tokens

const std::array routes_status_path_tokens
static
Initial value:
{
make_json_pointer_token("/routes/{routeName}/status"),
}

◆ routes_summary_def_tokens

const std::array routes_summary_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RouteSummary"),
}

◆ routing_status_def_tokens

const std::array routing_status_def_tokens
static
Initial value:
{
make_json_pointer_token("definitions"),
make_json_pointer_token("RoutingGlobalStatus"),
}

◆ routing_status_path_tokens

const std::array routing_status_path_tokens
static
Initial value:
{
make_json_pointer_token("/routing/status"),
}

◆ tags_append_tokens

const std::array tags_append_tokens
static
Initial value: