24#ifndef RPL_ASYNC_CONN_FAILOVER_CONFIGURATION_PROPAGATION_INCLUDED
25#define RPL_ASYNC_CONN_FAILOVER_CONFIGURATION_PROPAGATION_INCLUDED
30#include "sql/protobuf/generated/protobuf_lite/replication_asynchronous_connection_failover.pb.h"
131 std::map<std::pair<std::string, std::string>,
int>
m_status;
177 bool receive(
const char *tag,
const unsigned char *data,
size_t data_length);
263 const std::vector<std::string>
264 &exchanged_replication_failover_channels_serialized_configuration);
281 "mysql_replication_asynchronous_connection_failover",
282 "mysql_replication_asynchronous_connection_managed",
283 "mysql_replication_asynchronous_connection_variable_status",
284 "mysql_replication_asynchronous_connection_failover_and_managed_and_"
291 const std::string
m_db{
"mysql"};
295 "replication_asynchronous_connection_failover"};
302 "replication_asynchronous_connection_failover_managed"};
389 bool send(
const char *tag,
const char *data,
size_t data_length);
415 bool send_managed(
const char *data,
size_t data_length);
Definition: rpl_async_conn_failover_configuration_propagation.h:144
bool get_configuration(std::string &serialized_configuration)
Get data stored in mysql.replication_asynchronous_connection_failover or mysql.replication_asynchrono...
Definition: rpl_async_conn_failover_configuration_propagation.cc:702
bool set_configuration(const std::vector< std::string > &exchanged_replication_failover_channels_serialized_configuration)
Save data in mysql.replication_asynchronous_connection_failover or mysql.replication_asynchronous_con...
Definition: rpl_async_conn_failover_configuration_propagation.cc:793
bool receive(const char *tag, const unsigned char *data, size_t data_length)
Receive data sent by group replication group member.
Definition: rpl_async_conn_failover_configuration_propagation.cc:310
void reload_failover_channels_status()
Reload the failover channel status from runtime information.
Definition: rpl_async_conn_failover_configuration_propagation.cc:697
bool send_failover(const char *data, size_t data_length)
Send mysql.replication_asynchronous_connection_failover table data to group replication group members...
Definition: rpl_async_conn_failover_configuration_propagation.cc:483
bool send_failover_data(Rpl_sys_table_access &table_op)
Get stored data in mysql.replication_asynchronous_connection_failover table and send to its group rep...
Definition: rpl_async_conn_failover_configuration_propagation.cc:643
bool receive_channel_status(const unsigned char *data, size_t data_length)
Receive SOURCE_CONNECTION_AUTO_FAILOVER value of CHANGE REPLICATION SOURCE command data sent by group...
Definition: rpl_async_conn_failover_configuration_propagation.cc:460
bool send(const char *tag, const char *data, size_t data_length)
Send data to all group replication group members.
Definition: rpl_async_conn_failover_configuration_propagation.cc:501
bool send_channel_status(const char *data, size_t data_length)
Send SOURCE_CONNECTION_AUTO_FAILOVER value of CHANGE REPLICATION SOURCE command data to group replica...
Definition: rpl_async_conn_failover_configuration_propagation.cc:495
bool init()
Initialize and configure group_replication_message_service_recv service so member can receive and pro...
Definition: rpl_async_conn_failover_configuration_propagation.cc:278
bool receive_failover_and_managed_and_status(const unsigned char *data, size_t data_length)
Receive mysql.replication_asynchronous_connection_failover and mysql.replication_asynchronous_connect...
Definition: rpl_async_conn_failover_configuration_propagation.cc:902
virtual ~Rpl_acf_configuration_handler()
Destruction.
Definition: rpl_async_conn_failover_configuration_propagation.cc:276
Rpl_acf_configuration_handler()
Construction.
Definition: rpl_async_conn_failover_configuration_propagation.cc:274
const std::string m_db
Definition: rpl_async_conn_failover_configuration_propagation.h:291
Rpl_acf_status_configuration m_rpl_failover_channels_status
Definition: rpl_async_conn_failover_configuration_propagation.h:313
const std::string m_table_failover
Definition: rpl_async_conn_failover_configuration_propagation.h:294
bool set_failover_managed_internal(const protobuf_replication_asynchronous_connection_failover::SourceAndManagedAndStatusList &configuration)
Save data in mysql.replication_asynchronous_connection_failover_managed table.
Definition: rpl_async_conn_failover_configuration_propagation.cc:987
bool set_failover_sources_internal(const protobuf_replication_asynchronous_connection_failover::SourceAndManagedAndStatusList &configuration)
Save data in mysql.replication_asynchronous_connection_failover table.
Definition: rpl_async_conn_failover_configuration_propagation.cc:935
const uint m_table_failover_num_field
Definition: rpl_async_conn_failover_configuration_propagation.h:298
bool send_managed_data(Rpl_sys_table_access &table_op)
Get stored data in mysql.replication_asynchronous_connection_failover_managed table and send to its g...
Definition: rpl_async_conn_failover_configuration_propagation.cc:588
bool receive_managed(const unsigned char *data, size_t data_length)
Receive mysql.replication_asynchronous_connection_failover_managed table data sent by group replicati...
Definition: rpl_async_conn_failover_configuration_propagation.cc:389
bool send_table_data(Rpl_sys_table_access &table_op)
Get stored data in mysql.replication_asynchronous_connection_failover or mysql.replication_asynchrono...
Definition: rpl_async_conn_failover_configuration_propagation.cc:686
const std::string m_table_managed
Definition: rpl_async_conn_failover_configuration_propagation.h:301
bool receive_failover(const unsigned char *data, size_t data_length)
Receive mysql.replication_asynchronous_connection_failover table data sent by group replication group...
Definition: rpl_async_conn_failover_configuration_propagation.cc:328
bool send_channel_status_and_version_data(const std::string &channel, Rpl_acf_status_configuration::enum_key key, int status)
Send variable status to its group replication group members.
Definition: rpl_async_conn_failover_configuration_propagation.cc:550
bool force_my_replication_failover_channels_configuration_on_all_members()
Collect and broadcast the replication failover channels configuration in a serialized protobuf_replic...
Definition: rpl_async_conn_failover_configuration_propagation.cc:889
const std::vector< std::string > m_message_tag
Definition: rpl_async_conn_failover_configuration_propagation.h:280
void delete_channel_status(const std::string &channel, Rpl_acf_status_configuration::enum_key key)
Delete channel status.
Definition: rpl_async_conn_failover_configuration_propagation.cc:582
bool deinit()
Unregister group_replication_message_service_recv service.
Definition: rpl_async_conn_failover_configuration_propagation.cc:300
bool send_managed(const char *data, size_t data_length)
Send mysql.replication_asynchronous_connection_failover_managed table data to group replication group...
Definition: rpl_async_conn_failover_configuration_propagation.cc:489
const uint m_table_managed_num_field
Definition: rpl_async_conn_failover_configuration_propagation.h:307
Memory storage of the replication failover channel status configuration propagated to Group Replicati...
Definition: rpl_async_conn_failover_configuration_propagation.h:37
void reload()
Reloads the status configuration from runtime information.
Definition: rpl_async_conn_failover_configuration_propagation.cc:92
virtual ~Rpl_acf_status_configuration()
Definition: rpl_async_conn_failover_configuration_propagation.cc:63
static std::string get_key_name(Rpl_acf_status_configuration::enum_key key)
Definition: rpl_async_conn_failover_configuration_propagation.cc:67
void delete_channel_status(const std::string &channel, Rpl_acf_status_configuration::enum_key key)
Delete the status configuration value.
Definition: rpl_async_conn_failover_configuration_propagation.cc:122
enum_key
Status keys propagated with the group.
Definition: rpl_async_conn_failover_configuration_propagation.h:46
@ SOURCE_CONNECTION_AUTO_FAILOVER
Definition: rpl_async_conn_failover_configuration_propagation.h:46
mysql_mutex_t m_lock
Definition: rpl_async_conn_failover_configuration_propagation.h:122
bool set(const protobuf_replication_asynchronous_connection_failover::VariableStatusList &configuration)
Sets the status configuration with the one received from the group.
Definition: rpl_async_conn_failover_configuration_propagation.cc:166
std::map< std::pair< std::string, std::string >, int > m_status
Definition: rpl_async_conn_failover_configuration_propagation.h:131
void set_value_and_increment_version(const std::string &channel, Rpl_acf_status_configuration::enum_key key, int value, protobuf_replication_asynchronous_connection_failover::VariableStatusList &configuration)
Sets the status configuration value and increment version value.
Definition: rpl_async_conn_failover_configuration_propagation.cc:138
Rpl_acf_status_configuration()
Definition: rpl_async_conn_failover_configuration_propagation.cc:59
bool reset()
Clears the status configuration.
Definition: rpl_async_conn_failover_configuration_propagation.cc:73
static const std::vector< std::string > m_key_names
Definition: rpl_async_conn_failover_configuration_propagation.h:133
ulonglong m_version
Definition: rpl_async_conn_failover_configuration_propagation.h:124
void get(protobuf_replication_asynchronous_connection_failover::SourceAndManagedAndStatusList &configuration)
Gets the status configuration to send to the group.
Definition: rpl_async_conn_failover_configuration_propagation.cc:254
The class are wrappers for handler index and random scan functions to simplify their usage.
Definition: rpl_sys_table_access.h:45
unsigned long long int ulonglong
Definition: my_inttypes.h:56
Definition: rpl_async_conn_failover_table_operations.h:37
required string key
Definition: replication_asynchronous_connection_failover.proto:60
required string configuration
Definition: replication_asynchronous_connection_failover.proto:49
required uint32 status
Definition: replication_asynchronous_connection_failover.proto:61
message SourceAndManagedAndStatusList
Definition: replication_asynchronous_connection_failover.proto:70
message VariableStatusList
Definition: replication_asynchronous_connection_failover.proto:64
An instrumented mutex structure.
Definition: mysql_mutex_bits.h:50