MySQL 9.1.0
Source Code Documentation
rpl_group_replication.h
Go to the documentation of this file.
1/* Copyright (c) 2013, 2024, Oracle and/or its affiliates.
2
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License, version 2.0,
5 as published by the Free Software Foundation.
6
7 This program is designed to work with certain software (including
8 but not limited to OpenSSL) that is licensed under separate terms,
9 as designated in a particular file or component or in included license
10 documentation. The authors of MySQL hereby grant you an additional
11 permission to link the program and your derivative works with the
12 separately licensed software that they have either included with
13 the program or referenced in the documentation.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License, version 2.0, for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
23
24#ifndef RPL_GROUP_REPLICATION_INCLUDED
25#define RPL_GROUP_REPLICATION_INCLUDED
26
27#include <violite.h>
28#include <string>
29
30class THD;
35
36/*
37 Group Replication plugin handler function accessors.
38*/
40
41int group_replication_start(char **error_message, THD *thd);
42int group_replication_stop(char **error_message);
46 View_change_log_event *view_change_event);
47
51 unsigned int index,
54 unsigned int index,
57/**
58 Getter to extract the group_name in GR which, this can be used
59 outside GR to find out the group name.
60*/
62
63/**
64 Getter to extract the value of variable group_replication_view_change_uuid in
65 Group Replication.
66
67 If group_replication_view_change_uuid variable isn't defined or service
68 retrieves error when getting variable it will return default value
69 "AUTOMATIC".
70
71 @param[out] uuid Retrieves value of variable group_replication_view_change
72
73 @return the operation status
74 @retval false OK
75 @retval true Error
76*/
77bool get_group_replication_view_change_uuid(std::string &uuid);
78
79/**
80 Checks if this member is part of a group in single-primary mode and if
81 this member is a secondary.
82
83 @return status
84 @retval true this member is part of a group in single-primary mode
85 and is a secondary
86 @retval false otherwise
87*/
89
90// Callback definition for socket donation
91typedef int (*gr_incoming_connection_cb)(THD *thd, int fd, SSL *ssl_ctx);
93
94#endif /* RPL_GROUP_REPLICATION_INCLUDED */
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:36
This is the subclass of View_change_log_event and Log_event This class created the view_change_log_ev...
Definition: log_event.h:4485
void set_gr_incoming_connection(gr_incoming_connection_cb x)
Definition: sql_parse.cc:1619
bool is_group_replication_running()
Definition: rpl_group_replication.cc:240
int group_replication_stop(char **error_message)
Definition: rpl_group_replication.cc:211
std::string get_group_replication_group_name()
Getter to extract the group_name in GR which, this can be used outside GR to find out the group name.
Definition: rpl_group_replication.cc:596
bool is_group_replication_plugin_loaded()
Definition: rpl_group_replication.cc:110
bool get_group_replication_group_member_stats_info(unsigned int index, const GROUP_REPLICATION_GROUP_MEMBER_STATS_CALLBACKS &callbacks)
Definition: rpl_group_replication.cc:324
bool get_group_replication_group_members_info(unsigned int index, const GROUP_REPLICATION_GROUP_MEMBERS_CALLBACKS &callbacks)
Definition: rpl_group_replication.cc:306
bool get_group_replication_view_change_uuid(std::string &uuid)
Getter to extract the value of variable group_replication_view_change_uuid in Group Replication.
Definition: rpl_group_replication.cc:624
bool is_group_replication_cloning()
Definition: rpl_group_replication.cc:256
bool get_group_replication_connection_status_info(const GROUP_REPLICATION_CONNECTION_STATUS_CALLBACKS &callbacks)
Definition: rpl_group_replication.cc:289
unsigned int get_group_replication_members_number_info()
Definition: rpl_group_replication.cc:342
bool is_group_replication_member_secondary()
Checks if this member is part of a group in single-primary mode and if this member is a secondary.
Definition: rpl_group_replication.cc:673
int(* gr_incoming_connection_cb)(THD *thd, int fd, SSL *ssl_ctx)
Definition: rpl_group_replication.h:91
int set_group_replication_retrieved_certification_info(View_change_log_event *view_change_event)
Definition: rpl_group_replication.cc:272
int group_replication_start(char **error_message, THD *thd)
Definition: rpl_group_replication.cc:124
Definition: plugin_group_replication.h:54
Definition: plugin_group_replication.h:73
Definition: plugin_group_replication.h:101
Vio Lite.