MySQL  8.0.19
Source Code Documentation
group_replication_priv.h File Reference

Go to the source code of this file.

Functions

int group_replication_init ()
 Server side initializations. More...
 
my_thread_attr_tget_connection_attrib ()
 Returns the server connection attribute. More...
 
void get_server_parameters (char **hostname, uint *port, char **uuid, unsigned int *server_version)
 Returns the server hostname, port and uuid. More...
 
void get_server_ssl_parameters (st_server_ssl_variables *server_ssl_variables)
 Returns the server ssl configuration values. More...
 
ulong get_server_id ()
 Returns the server_id. More...
 
ulong get_auto_increment_increment ()
 Returns the server auto_increment_increment. More...
 
ulong get_auto_increment_offset ()
 Returns the server auto_increment_offset. More...
 
void set_auto_increment_increment (ulong auto_increment_increment)
 Set server auto_increment_increment. More...
 
void set_auto_increment_offset (ulong auto_increment_offset)
 Set server auto_increment_offset. More...
 
void get_server_startup_prerequirements (Trans_context_info &requirements, bool has_lock)
 Returns a struct containing all server startup information needed to evaluate if one has conditions to proceed executing master-master replication. More...
 
bool get_server_encoded_gtid_executed (uchar **encoded_gtid_executed, size_t *length)
 Returns the server GTID_EXECUTED encoded as a binary string. More...
 
char * encoded_gtid_set_to_string (uchar *encoded_gtid_set, size_t length)
 Returns a text representation of a encoded GTID set. More...
 
rpl_gno get_last_executed_gno (rpl_sidno sidno)
 Return last gno for a given sidno, see Gtid_state::get_last_executed_gno() for details. More...
 
rpl_sidno get_sidno_from_global_sid_map (rpl_sid sid)
 Return sidno for a given sid, see Sid_map::add_sid() for details. More...
 
void set_slave_thread_options (THD *thd)
 Set slave thread default options. More...
 
void global_thd_manager_add_thd (THD *thd)
 Add thread to Global_THD_manager singleton. More...
 
void global_thd_manager_remove_thd (THD *thd)
 Remove thread from Global_THD_manager singleton. More...
 
const char * get_write_set_algorithm_string (unsigned int algorithm)
 Function that returns the write set extraction algorithm name. More...
 
bool is_gtid_committed (const Gtid &gtid)
 Returns true if the given transaction is committed. More...
 
unsigned long get_slave_max_allowed_packet ()
 Returns the value of slave_max_allowed_packet. More...
 
unsigned long get_max_slave_max_allowed_packet ()
 
bool is_server_restarting_after_clone ()
 

Function Documentation

◆ encoded_gtid_set_to_string()

char* encoded_gtid_set_to_string ( uchar encoded_gtid_set,
size_t  length 
)

Returns a text representation of a encoded GTID set.

Note
Memory allocated to returned pointer must be release by caller.
Parameters
[in]encoded_gtid_setbinary string
[in]lengthbinary string length
Returns
a pointer to text representation of the encoded set

◆ get_auto_increment_increment()

ulong get_auto_increment_increment ( )

Returns the server auto_increment_increment.

Returns
auto_increment_increment

◆ get_auto_increment_offset()

ulong get_auto_increment_offset ( )

Returns the server auto_increment_offset.

Returns
auto_increment_offset

◆ get_connection_attrib()

my_thread_attr_t* get_connection_attrib ( )

Returns the server connection attribute.

Note
This method implementation is on sql_class.cc
Returns
the pthread for the connection attribute.

Returns the server connection attribute.

Return values
Referenceto thread attribute for connection threads

◆ get_last_executed_gno()

rpl_gno get_last_executed_gno ( rpl_sidno  sidno)

Return last gno for a given sidno, see Gtid_state::get_last_executed_gno() for details.

◆ get_max_slave_max_allowed_packet()

unsigned long get_max_slave_max_allowed_packet ( )
Returns
the maximum value of slave_max_allowed_packet.

◆ get_server_encoded_gtid_executed()

bool get_server_encoded_gtid_executed ( uchar **  encoded_gtid_executed,
size_t *  length 
)

Returns the server GTID_EXECUTED encoded as a binary string.

Note
Memory allocated to encoded_gtid_executed must be release by caller.
Parameters
[out]encoded_gtid_executedbinary string
[out]lengthbinary string length

◆ get_server_id()

ulong get_server_id ( )

Returns the server_id.

Returns
server_id

◆ get_server_parameters()

void get_server_parameters ( char **  hostname,
uint port,
char **  uuid,
unsigned int *  server_version 
)

Returns the server hostname, port and uuid.

Parameters
[out]hostname
[out]port
[out]uuid
[out]server_version

◆ get_server_ssl_parameters()

void get_server_ssl_parameters ( st_server_ssl_variables server_ssl_variables)

Returns the server ssl configuration values.

Parameters
[out]server_ssl_variables

◆ get_server_startup_prerequirements()

void get_server_startup_prerequirements ( Trans_context_info requirements,
bool  has_lock 
)

Returns a struct containing all server startup information needed to evaluate if one has conditions to proceed executing master-master replication.

Parameters
[out]requirements
[in]has_lockCaller should set this to true if the calling thread holds gtid_mode_lock; otherwise set it to false.

◆ get_sidno_from_global_sid_map()

rpl_sidno get_sidno_from_global_sid_map ( rpl_sid  sid)

Return sidno for a given sid, see Sid_map::add_sid() for details.

◆ get_slave_max_allowed_packet()

unsigned long get_slave_max_allowed_packet ( )

Returns the value of slave_max_allowed_packet.

Returns
slave_max_allowed_packet

◆ get_write_set_algorithm_string()

const char* get_write_set_algorithm_string ( unsigned int  algorithm)

Function that returns the write set extraction algorithm name.

Parameters
[in]algorithmThe algorithm value
Returns
the algorithm name

◆ global_thd_manager_add_thd()

void global_thd_manager_add_thd ( THD thd)

Add thread to Global_THD_manager singleton.

Parameters
[in]thdThe thread

◆ global_thd_manager_remove_thd()

void global_thd_manager_remove_thd ( THD thd)

Remove thread from Global_THD_manager singleton.

Parameters
[in]thdThe thread

◆ group_replication_init()

int group_replication_init ( )

Server side initializations.

◆ is_gtid_committed()

bool is_gtid_committed ( const Gtid gtid)

Returns true if the given transaction is committed.

Parameters
[in]gtidThe transaction identifier
Returns
true the transaction is committed false otherwise

◆ is_server_restarting_after_clone()

bool is_server_restarting_after_clone ( )
Returns
if the server is restarting after a clone

◆ set_auto_increment_increment()

void set_auto_increment_increment ( ulong  auto_increment_increment)

Set server auto_increment_increment.

Parameters
[in]auto_increment_increment

◆ set_auto_increment_offset()

void set_auto_increment_offset ( ulong  auto_increment_offset)

Set server auto_increment_offset.

Parameters
[in]auto_increment_offset