MySQL 5.6.14 Source Code Document
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ConfigInfo Class Reference

Metainformation about ALL cluster configuration parameters. More...

#include <ConfigInfo.hpp>

Collaboration diagram for ConfigInfo:

Classes

struct  AliasPair
struct  ConfigRule
struct  ConfigRuleSection
struct  ParamInfo
class  ParamInfoIter
struct  SectionRule
struct  Typelib

Public Types

enum  Type {
  CI_BOOL, CI_INT, CI_INT64, CI_STRING,
  CI_ENUM, CI_BITMASK, CI_SECTION
}
enum  Status {
  CI_USED, CI_EXPERIMENTAL, CI_DEPRECATED, CI_NOTIMPLEMENTED,
  CI_INTERNAL
}
enum  Flags { CI_ONLINE_UPDATEABLE = 1, CI_CHECK_WRITABLE = 2, CI_RESTART_SYSTEM = 4, CI_RESTART_INITIAL = 8 }

Public Member Functions

bool verify (const Properties *secti, const char *fname, Uint64 value) const
bool verify_enum (const Properties *section, const char *fname, const char *value, Uint32 &value_int) const
void get_enum_values (const Properties *section, const char *fname, BaseString &err) const
bool isSection (const char *) const
const char * getDescription (const Properties *sec, const char *fname) const
Type getType (const Properties *section, const char *fname) const
Status getStatus (const Properties *section, const char *fname) const
Uint64 getMin (const Properties *section, const char *fname) const
Uint64 getMax (const Properties *section, const char *fname) const
Uint64 getDefault (const Properties *section, const char *fname) const
Uint32 getFlags (const Properties *section, const char *fname) const
const char * getDefaultString (const Properties *section, const char *fname) const
bool getMandatory (const Properties *section, const char *fname) const
bool hasDefault (const Properties *section, const char *fname) const
const PropertiesgetInfo (const char *section) const
const PropertiesgetDefaults (const char *section) const
const char * sectionName (Uint32 section_type, Uint32 type) const
void print (const char *section=NULL) const
void print_xml (const char *section=NULL) const

Static Public Member Functions

static Uint32 getSectionType (const ParamInfo &p)
static const TypelibgetTypelibPtr (const ParamInfo &p)
static const char * nameToAlias (const char *)
static const char * getAlias (const char *)

Static Public Attributes

static const ParamInfo m_ParamInfo []
static const int m_NoOfParams = sizeof(m_ParamInfo) / sizeof(ParamInfo)
static const SectionRule m_SectionRules []
static const ConfigRule m_ConfigRules []
static const int m_NoOfRules = sizeof(m_SectionRules)/sizeof(SectionRule)

Detailed Description

Metainformation about ALL cluster configuration parameters.

Use the getters to find out metainformation about parameters.

Definition at line 38 of file ConfigInfo.hpp.

Member Enumeration Documentation

Enumerator:
CI_USED 

Active.

CI_EXPERIMENTAL 

Active but experimental.

CI_DEPRECATED 

Can be used, but shouldn't.

CI_NOTIMPLEMENTED 

Is ignored.

CI_INTERNAL 

Not configurable by the user.

Definition at line 48 of file ConfigInfo.hpp.

Member Function Documentation

static Uint32 ConfigInfo::getSectionType ( const ParamInfo p)
inlinestatic

section type is stored in _default

Definition at line 129 of file ConfigInfo.hpp.

static const Typelib* ConfigInfo::getTypelibPtr ( const ParamInfo p)
inlinestatic

typelib ptr is stored in _min

Definition at line 137 of file ConfigInfo.hpp.

bool ConfigInfo::verify ( const Properties secti,
const char *  fname,
Uint64  value 
) const

Checks if the suggested value is valid for the suggested parameter (i.e. if it is >= than min and <= than max).

Parameters
sectionInit Config file section name
fnameName of parameter
valueValue to check
Returns
true if parameter value is valid.
Note
Result is not defined if section/name are wrong!

Definition at line 3662 of file ConfigInfo.cpp.

Member Data Documentation

const ConfigInfo::ConfigRule ConfigInfo::m_ConfigRules
static
Initial value:
{
{ add_system_section, 0 },
{ sanity_checks, 0 },
{ add_node_connections, 0 },
{ set_connection_priorities, 0 },
{ check_node_vs_replicas, 0 },
{ check_mutually_exclusive, 0 },
{ saveSectionsInConfigValues, "SYSTEM,Node,Connection" },
{ 0, 0 }
}

Definition at line 245 of file ConfigInfo.hpp.

const ConfigInfo::ParamInfo ConfigInfo::m_ParamInfo
static

The default constructors create objects with suitable values for the configuration parameters.

Some are however given the value MANDATORY which means that the value must be specified in the configuration file.

Min and max values are also given for some parameters.

  • Attr1: Name in file (initial config file)
  • Attr2: Name in prop (properties object)
  • Attr3: Name of Section (in init config file)
  • Attr4: Updateable
  • Attr5: Type of parameter (INT or BOOL)
  • Attr6: Default Value (number only)
  • Attr7: Min value
  • Attr8: Max value

Parameter constraints are coded in file Config.cpp.


Parameters used under development should be marked "NOTIMPLEMENTED"

Definition at line 240 of file ConfigInfo.hpp.


The documentation for this class was generated from the following files: