MySQL  8.0.27
Source Code Documentation
rpl_channel_service_interface.h
Go to the documentation of this file.
1 /* Copyright (c) 2015, 2021, 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 also distributed 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 included with MySQL.
13 
14  This program is distributed in the hope that it will be useful,
15  but WITHOUT ANY WARRANTY; without even the implied warranty of
16  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  GNU General Public License, version 2.0, for more details.
18 
19  You should have received a copy of the GNU General Public License
20  along with this program; if not, write to the Free Software
21  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
22 
23 #ifndef RPL_SERVICE_INTERFACE_INCLUDE
24 #define RPL_SERVICE_INTERFACE_INCLUDE
25 
26 #include <string>
27 #include <vector>
28 
29 // Channel errors
30 
31 #define RPL_CHANNEL_SERVICE_RECEIVER_CONNECTION_ERROR -1
32 #define RPL_CHANNEL_SERVICE_DEFAULT_CHANNEL_CREATION_ERROR -2
33 #define RPL_CHANNEL_SERVICE_SLAVE_SKIP_COUNTER_ACTIVE -3
34 #define RPL_CHANNEL_SERVICE_CHANNEL_DOES_NOT_EXISTS_ERROR -4
35 // Error for the wait event consumption, equal to the server wait for GTID
36 // method
37 #define REPLICATION_THREAD_WAIT_TIMEOUT_ERROR -1
38 #define REPLICATION_THREAD_WAIT_NO_INFO_ERROR -2
39 
40 // Settings
41 
42 // Used whenever a parameter should take the server default value
43 #define RPL_SERVICE_SERVER_DEFAULT -1
44 
45 // Channel creation settings
46 
47 /**
48  Types of channels
49 */
51  SLAVE_REPLICATION_CHANNEL, // Master slave replication channels
52  GROUP_REPLICATION_CHANNEL // Group replication channels
53 };
54 
55 /**
56  Know parallelization options that can be applied to channel appliers
57 */
61 };
62 
63 /**
64  SSL information to be used when creating a channel.
65  It maps the SSL options present in a CHANGE MASTER.
66 */
68  int use_ssl; // use SSL
69  char *ssl_ca_file_name; // SSL list of trusted certificate authorities
70  char *ssl_ca_directory; // SSL certificate authorities directory
71  char *ssl_cert_file_name; // SSL connection certificate
72  char *ssl_crl_file_name; // SSL certificate revocation list
73  char *ssl_crl_directory; // SSL certificate revocation list file directory
74  char *ssl_key; // SSL key file for connections
75  char *ssl_cipher; // list of permissible ciphers to use for SSL
76  int ssl_verify_server_cert; // check the server's Common Name value
77  char *tls_version; // TLS version to use for SSL
78  char *tls_ciphersuites; // list of permissible ciphersuites for TLS 1.3
79 };
80 
81 void initialize_channel_ssl_info(Channel_ssl_info *channel_ssl_info);
82 
83 /**
84  Creation information for a channel.
85  It includes the data that is usually associated to a change master command
86 */
89  char *hostname;
90  int port;
91  char *user;
92  char *password;
99  int thd_tx_priority; // The applier thread priority
101  int connect_retry; // How many seconds to wait between retries.
102  int retry_count; // Limits the number of reconnection attempts
103  bool preserve_relay_logs; // If the logs should be preserved on creation
104  char *public_key_path; // RSA Public key information
105  int get_public_key; // Preference to get public key from donor if not
106  // available
109  /* to enable async connection failover */
113 };
114 
116 
117 // Start settings
118 
119 /**
120  The known types of channel threads.
121  All new types should be power of 2
122 */
127 };
128 
129 /**
130  The known until conditions that can be applied to channels
131 */
138 };
139 
140 /**
141  Channel information to connect to a receiver
142 */
144  int until_condition; // base on enum_channel_until_condition
145  char *gtid; // Gtids to wait on a until condition
146  char *view_id; // The view id to wait on a until condition
147 };
148 
150 
151 /**
152  Initializes a channel connection in a similar way to a change master command.
153 
154  @note If the channel exists, it is reconfigured with the new options.
155  About the logs, the preserve_relay_logs option allows the user to
156  maintain them untouched.
157 
158  @param channel The channel name
159  @param channel_information Channel creation information.
160 
161  @return the operation status
162  @retval 0 OK
163  @retval !=0 Error on channel creation
164 */
165 int channel_create(const char *channel,
166  Channel_creation_info *channel_information);
167 
168 /**
169  Start the Applier/Receiver threads according to the given options.
170  If the receiver thread is to be started, connection credential must be
171  supported.
172 
173  @param channel The channel name
174  @param connection_info Channel connection information
175  @param threads_to_start The types of threads to be started
176  @param wait_for_connection If when starting the receiver, the method should
177  wait for the connection to succeed
178  @param use_server_mta_configuration
179  If true, the channel uses the server parallel
180  applier configuration when starting the applier
181  thread, instead of the configuration given on
182  `channel_create()`
183  @param channel_map_already_locked
184  If set to true, will not acquire a write
185  lock of channel_map
186 
187  @return the operation status
188  @retval 0 OK
189  @retval !=0 Error
190  */
191 int channel_start(const char *channel, Channel_connection_info *connection_info,
192  int threads_to_start, int wait_for_connection,
193  bool use_server_mta_configuration = false,
194  bool channel_map_already_locked = false);
195 
196 /**
197  Stops the channel threads according to the given options.
198 
199  @param channel The channel name
200  @param threads_to_stop The types of threads to be stopped
201  @param timeout The expected time in which the thread should stop
202  @return the operation status
203  @retval 0 OK
204  @retval !=0 Error
205 */
206 int channel_stop(const char *channel, int threads_to_stop, long timeout);
207 
208 /**
209  Kills the Binlog Dump threads.
210 
211  @return the operation status
212  @retval 0 OK
213 */
215 
216 /**
217  Stops all the running channel threads according to the given options.
218 
219  @param threads_to_stop The types of threads to be stopped
220  @param timeout The expected time in which the thread should stop
221  @param error_message The returned error_message
222 
223  @return the operation status
224  @retval 0 OK
225  @retval !=0 Error
226 */
227 int channel_stop_all(int threads_to_stop, long timeout,
228  std::string *error_message);
229 /**
230  Purges the channel logs
231 
232  @param channel The channel name
233  @param reset_all If true, the method will purge logs and remove the channel
234  If false, only the channel information will be reset.
235 
236  @return the operation status
237  @retval 0 OK
238  @retval !=0 Error
239 */
240 int channel_purge_queue(const char *channel, bool reset_all);
241 
242 /**
243  Tells if the selected component of the channel is active or not.
244  If no component is passed, this method returns if the channel exists or not
245 
246  @param channel The channel name
247  @param type The thread that should be checked.
248  If 0, this method applies to the channel existence.
249 
250  @return is the channel (component) active
251  @retval true Yes
252  @retval false No
253 */
255 
256 /**
257  Returns the id(s) of the channel threads: receiver or applier.
258  If more than one applier exists, an array is returned, on which first
259  index is coordinator thread id.
260 
261  @param[in] channel The channel name
262  @param[in] thread_type The thread type (receiver or applier)
263  @param[out] thread_id The array of id(s)
264 
265  @return the number of returned ids
266  @retval -1 the channel does no exists, or the thread is not present
267  @retval >0 the number of thread ids returned.
268 */
269 int channel_get_thread_id(const char *channel,
270  enum_channel_thread_types thread_type,
271  unsigned long **thread_id);
272 
273 /**
274  Returns last GNO from applier from a given UUID.
275 
276  @param channel the channel name
277  @param sidno the uuid associated to the desired gno
278 
279  @return the last applier gno
280  @retval <0 the channel does no exists, or the applier is not present
281  @retval >0 the gno
282 */
283 long long channel_get_last_delivered_gno(const char *channel, int sidno);
284 
285 /**
286  Adds server executed GTID set to channel received GTID set.
287 
288  @param channel the channel name
289 
290  @return the operation status
291  @retval 0 OK
292  @retval != 0 Error
293 */
295 
296 /**
297  Queues a event packet into the current active channel.
298 
299  @param channel the channel name
300  @param buf the event buffer
301  @param len the event buffer length
302 
303  @return the operation status
304  @retval 0 OK
305  @retval != 0 Error on queue
306 */
307 int channel_queue_packet(const char *channel, const char *buf,
308  unsigned long len);
309 
310 /**
311  Checks if all the queued transactions were executed.
312 
313  @note This method assumes that the channel is not receiving any more events.
314  If it is still receiving, then the method should wait for execution of
315  transactions that were present when this method was invoked.
316 
317  @param channel the channel name
318  @param timeout the time (seconds) after which the method returns if the
319  above condition was not satisfied
320 
321  @return the operation status
322  @retval 0 All transactions were executed
323  @retval REPLICATION_THREAD_WAIT_TIMEOUT_ERROR A timeout occurred
324  @retval REPLICATION_THREAD_WAIT_NO_INFO_ERROR An error occurred
325 */
327 
328 /**
329  Checks if all the transactions in the given set were executed.
330 
331  @param channel the channel name
332  @param gtid_set the set in string format of transaction to wait for
333  @param timeout the time (seconds) after which the method returns if the
334  above condition was not satisfied
335  @param update_THD_status Shall the method update the THD stage
336 
337  @return the operation status
338  @retval 0 All transactions were executed
339  @retval REPLICATION_THREAD_WAIT_TIMEOUT_ERROR A timeout occurred
340  @retval REPLICATION_THREAD_WAIT_NO_INFO_ERROR An error occurred
341 */
343  const char *gtid_set,
344  double timeout,
345  bool update_THD_status = true);
346 
347 /**
348  Checks if the applier, and its workers when parallel applier is
349  enabled, has already consumed all relay log, that is, applier is
350  waiting for transactions to be queued.
351 
352  @param channel The channel name
353 
354  @return the operation status
355  @retval <0 Error
356  @retval 0 Applier is not waiting
357  @retval 1 Applier is waiting
358 */
359 int channel_is_applier_waiting(const char *channel);
360 
361 /**
362  Checks if the applier thread, and its workers when parallel applier is
363  enabled, has already consumed all relay log, that is, applier thread
364  is waiting for transactions to be queued.
365 
366  @param thread_id the applier thread id to check
367  @param worker flag to indicate if thread is a parallel worker
368 
369  @return the operation status
370  @retval -1 Unable to find applier thread
371  @retval 0 Applier thread is not waiting
372  @retval 1 Applier thread is waiting
373 */
375  bool worker = false);
376 
377 /**
378  Flush the channel.
379 
380  @return the operation status
381  @retval 0 OK
382  @retval != 0 Error on flush
383 */
384 int channel_flush(const char *channel);
385 
386 /**
387  Initializes channel structures if needed.
388 
389  @return the operation status
390  @retval 0 OK
391  @retval != 0 Error on queue
392 */
394 
395 /**
396  Returns the receiver thread retrieved GTID set in string format.
397 
398  @param channel The channel name.
399  @param[out] retrieved_set Pointer to pointer to string. The function will
400  set it to point to a newly allocated buffer, or
401  NULL on out of memory.
402 
403  @return the operation status
404  @retval 0 OK
405  @retval !=0 Error on retrieval
406 */
407 int channel_get_retrieved_gtid_set(const char *channel, char **retrieved_set);
408 
409 /**
410  Tells if the selected component of the channel is stopping or not.
411 
412  @param channel The channel name
413  @param type The thread that should be checked.
414 
415  @return is the channel (component) stopping
416  @retval true Yes
417  @retval false No, no type was specified or the channel does not exist.
418 */
420 
421 /**
422  Checks if the given channel's relaylog contains a partial transaction.
423 
424  @param channel The channel name
425 
426  @retval true If relaylog contains partial transcation.
427  @retval false If relaylog does not contain partial transaction.
428 */
430 
431 /**
432  Checks if any slave threads of any channel is running
433 
434  @param[in] thread_mask type of slave thread- IO/SQL or any
435 
436  @retval true atleast one channel threads are running.
437  @retval false none of the the channels are running.
438 */
439 bool is_any_slave_channel_running(int thread_mask);
440 
441 /**
442  Checks if any slave threads of any channel configured with
443  SOURCE_CONNECTION_AUTO_FAILOVER is running.
444 
445  @param[in] thread_mask type of slave thread- IO/SQL or any
446 
447  @retval true at least one channel threads are running.
448  @retval false none of the the channels are running.
449 */
451 
452 /**
453  Checks if any running channel uses the same UUID for
454  assign_gtids_to_anonymous_transactions as the group_name
455 
456  @param[in] group_name the group name
457 
458  @retval true atleast one channel has the same uuid
459  @retval false none of the the channels have the same
460  uuid
461 */
462 bool channel_has_same_uuid_as_group_name(const char *group_name);
463 
464 /**
465  Method to get the credentials configured for a channel
466 
467  @param[in] channel The channel name
468  @param[out] user The user to extract
469  @param[out] password The password to extract
470 
471  @return the operation status
472  @retval false OK
473  @retval true Error, channel not found
474 */
475 int channel_get_credentials(const char *channel, std::string &user,
476  std::string &password);
477 
478 /**
479  Method to get the network namespace configured for a channel
480 
481  @param[in] channel The channel name
482  @param[out] net_ns The network namespace to extract
483 
484  @return the operation status
485  @retval false OK
486  @retval true Error, channel not found
487 */
488 int channel_get_network_namespace(const char *channel, std::string &net_ns);
489 
490 /**
491  Return type for function
492  has_any_slave_channel_open_temp_table_or_is_its_applier_running()
493 */
495  /*
496  None of all slave channel appliers are running and none
497  of all slave channels have open temporary table(s).
498  */
500  /* At least one slave channel applier is running. */
502  /* At least one slave channel has open temporary table(s). */
504 };
505 
506 /**
507  Checks if any slave channel applier is running or any slave channel has open
508  temporary table(s). This holds handled appliers' run_locks until finding a
509  running slave channel applier or a slave channel which has open temporary
510  table(s), or handling all slave channels.
511 
512  @return SLAVE_CHANNEL_NO_APPLIER_RUNNING_AND_NO_OPEN_TEMPORARY_TABLE,
513  SLAVE_CHANNEL_APPLIER_IS_RUNNING or
514  SLAVE_CHANNEL_HAS_OPEN_TEMPORARY_TABLE.
515 */
518 
519 /**
520  Delete stored credentials from Slave_credentials
521  @param[in] channel_name The channel name
522 
523  @return the operation status
524  @retval 0 OK
525  @retval 1 Error, channel not found
526 
527  */
528 int channel_delete_credentials(const char *channel_name);
529 
530 /**
531  Start channels which have SOURCE_CONNECTION_AUTO_FAILOVER=1.
532 
533  @return the operation status
534  @retval false OK
535  @retval true Error
536  */
538 
539 /**
540  Set SOURCE_CONNECTION_AUTO_FAILOVER on the given channel
541  to the given status value.
542 
543  @param[in] channel The channel name
544  @param[in] status true, enables SOURCE_CONNECTION_AUTO_FAILOVER
545  false, disables SOURCE_CONNECTION_AUTO_FAILOVER
546 
547  @return the operation status
548  @retval false OK
549  @retval true Error
550  */
552  bool status);
553 
554 /**
555  Unset SOURCE_CONNECTION_AUTO_FAILOVER=0 on all channels.
556 
557  @return the operation status
558  @retval false OK
559  @retval true Error
560  */
562 
563 /**
564  Reload the status values on `Rpl_acf_status_configuration`
565  singleton.
566  */
568 
569 /**
570  Get replication failover channels configuration in
571  a serialized
572  protobuf_replication_asynchronous_connection_failover::SourceAndManagedAndStatusList
573  message.
574 
575  @param[out] serialized_configuration the serialized configuration
576 
577  @return the operation status
578  @retval false OK
579  @retval true Error
580  */
582  std::string &serialized_configuration);
583 
584 /**
585  Set replication failover channels configuration that was
586  received from the group.
587  Each member of the group will send its own configuration
588  in a serialized
589  protobuf_replication_asynchronous_connection_failover::SourceAndManagedAndStatusList
590  message.
591 
592  @param[in] exchanged_replication_failover_channels_serialized_configuration
593  vector with the serialized configuration from each member
594 
595  @return the operation status
596  @retval false OK
597  @retval true Error
598  */
600  const std::vector<std::string>
601  &exchanged_replication_failover_channels_serialized_configuration);
602 
603 /**
604  Collect and broadcast the replication failover channels configuration
605  in a serialized
606  protobuf_replication_asynchronous_connection_failover::SourceAndManagedAndStatusList
607  message, that will override the configuration on all group members.
608 
609  @return the operation status
610  @retval false OK
611  @retval true Error
612  */
614 
615 #endif // RPL_SERVICE_INTERFACE_INCLUDE
static my_thread_id thread_id
Definition: my_thr_init.cc:62
static char * password
Definition: mysql_secure_installation.cc:55
char * user
Definition: mysqladmin.cc:59
Definition: buf0block_hint.cc:29
static bool timeout(bool(*wait_condition)())
Timeout function.
Definition: log0meb.cc:494
required uint32 status
Definition: replication_asynchronous_connection_failover.proto:60
required string type
Definition: replication_group_member_actions.proto:33
int channel_queue_packet(const char *channel, const char *buf, unsigned long len)
Queues a event packet into the current active channel.
Definition: rpl_channel_service_interface.cc:879
int channel_wait_until_transactions_applied(const char *channel, const char *gtid_set, double timeout, bool update_THD_status=true)
Checks if all the transactions in the given set were executed.
Definition: rpl_channel_service_interface.cc:938
enum_channel_until_condition
The known until conditions that can be applied to channels.
Definition: rpl_channel_service_interface.h:132
@ CHANNEL_UNTIL_APPLIER_AFTER_GAPS
Definition: rpl_channel_service_interface.h:136
@ CHANNEL_UNTIL_VIEW_ID
Definition: rpl_channel_service_interface.h:137
@ CHANNEL_UNTIL_APPLIER_AFTER_GTIDS
Definition: rpl_channel_service_interface.h:135
@ CHANNEL_UNTIL_APPLIER_BEFORE_GTIDS
Definition: rpl_channel_service_interface.h:134
@ CHANNEL_NO_UNTIL_CONDITION
Definition: rpl_channel_service_interface.h:133
int channel_start(const char *channel, Channel_connection_info *connection_info, int threads_to_start, int wait_for_connection, bool use_server_mta_configuration=false, bool channel_map_already_locked=false)
Start the Applier/Receiver threads according to the given options.
Definition: rpl_channel_service_interface.cc:417
bool is_any_slave_channel_running_with_failover_enabled(int thread_mask)
Checks if any slave threads of any channel configured with SOURCE_CONNECTION_AUTO_FAILOVER is running...
Definition: rpl_channel_service_interface.cc:1237
int channel_wait_until_apply_queue_applied(const char *channel, double timeout)
Checks if all the queued transactions were executed.
Definition: rpl_channel_service_interface.cc:899
bool is_any_slave_channel_running(int thread_mask)
Checks if any slave threads of any channel is running.
Definition: rpl_channel_service_interface.cc:1199
int channel_stop(const char *channel, int threads_to_stop, long timeout)
Stops the channel threads according to the given options.
Definition: rpl_channel_service_interface.cc:592
bool start_failover_channels()
Start channels which have SOURCE_CONNECTION_AUTO_FAILOVER=1.
Definition: rpl_channel_service_interface.cc:1335
void initialize_channel_connection_info(Channel_connection_info *channel_info)
Definition: rpl_channel_service_interface.cc:229
int binlog_dump_thread_kill()
Kills the Binlog Dump threads.
Definition: rpl_channel_service_interface.cc:667
int channel_delete_credentials(const char *channel_name)
Delete stored credentials from Slave_credentials.
Definition: rpl_channel_service_interface.cc:1329
int channel_create(const char *channel, Channel_creation_info *channel_information)
Initializes a channel connection in a similar way to a change master command.
Definition: rpl_channel_service_interface.cc:284
int channel_is_applier_thread_waiting(unsigned long thread_id, bool worker=false)
Checks if the applier thread, and its workers when parallel applier is enabled, has already consumed ...
Definition: rpl_channel_service_interface.cc:1014
enum_slave_channel_status
Return type for function has_any_slave_channel_open_temp_table_or_is_its_applier_running()
Definition: rpl_channel_service_interface.h:494
@ SLAVE_CHANNEL_HAS_OPEN_TEMPORARY_TABLE
Definition: rpl_channel_service_interface.h:503
@ SLAVE_CHANNEL_APPLIER_IS_RUNNING
Definition: rpl_channel_service_interface.h:501
@ SLAVE_CHANNEL_NO_APPLIER_RUNNING_AND_NO_OPEN_TEMPORARY_TABLE
Definition: rpl_channel_service_interface.h:499
bool get_replication_failover_channels_configuration(std::string &serialized_configuration)
Get replication failover channels configuration in a serialized protobuf_replication_asynchronous_con...
Definition: rpl_channel_service_interface.cc:1421
enum_channel_type
Types of channels.
Definition: rpl_channel_service_interface.h:50
@ GROUP_REPLICATION_CHANNEL
Definition: rpl_channel_service_interface.h:52
@ SLAVE_REPLICATION_CHANNEL
Definition: rpl_channel_service_interface.h:51
int channel_add_executed_gtids_to_received_gtids(const char *channel)
Adds server executed GTID set to channel received GTID set.
Definition: rpl_channel_service_interface.cc:858
int channel_get_thread_id(const char *channel, enum_channel_thread_types thread_type, unsigned long **thread_id)
Returns the id(s) of the channel threads: receiver or applier.
Definition: rpl_channel_service_interface.cc:731
void initialize_channel_creation_info(Channel_creation_info *channel_info)
Definition: rpl_channel_service_interface.cc:190
int channel_get_network_namespace(const char *channel, std::string &net_ns)
Method to get the network namespace configured for a channel.
Definition: rpl_channel_service_interface.cc:1112
void initialize_channel_ssl_info(Channel_ssl_info *channel_ssl_info)
Definition: rpl_channel_service_interface.cc:215
int channel_stop_all(int threads_to_stop, long timeout, std::string *error_message)
Stops all the running channel threads according to the given options.
Definition: rpl_channel_service_interface.cc:606
bool channel_has_same_uuid_as_group_name(const char *group_name)
Checks if any running channel uses the same UUID for assign_gtids_to_anonymous_transactions as the gr...
Definition: rpl_channel_service_interface.cc:1176
bool channel_change_source_connection_auto_failover(const char *channel, bool status)
Set SOURCE_CONNECTION_AUTO_FAILOVER on the given channel to the given status value.
Definition: rpl_channel_service_interface.cc:1366
int channel_purge_queue(const char *channel, bool reset_all)
Purges the channel logs.
Definition: rpl_channel_service_interface.cc:675
int channel_flush(const char *channel)
Flush the channel.
Definition: rpl_channel_service_interface.cc:1034
enum_slave_channel_status has_any_slave_channel_open_temp_table_or_is_its_applier_running()
Checks if any slave channel applier is running or any slave channel has open temporary table(s).
Definition: rpl_channel_service_interface.cc:1279
bool set_replication_failover_channels_configuration(const std::vector< std::string > &exchanged_replication_failover_channels_serialized_configuration)
Set replication failover channels configuration that was received from the group.
Definition: rpl_channel_service_interface.cc:1428
bool channel_is_stopping(const char *channel, enum_channel_thread_types type)
Tells if the selected component of the channel is stopping or not.
Definition: rpl_channel_service_interface.cc:1133
int channel_get_retrieved_gtid_set(const char *channel, char **retrieved_set)
Returns the receiver thread retrieved GTID set in string format.
Definition: rpl_channel_service_interface.cc:1053
void reload_failover_channels_status()
Reload the status values on Rpl_acf_status_configuration singleton.
Definition: rpl_channel_service_interface.cc:1414
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_channel_service_interface.cc:1439
long long channel_get_last_delivered_gno(const char *channel, int sidno)
Returns last GNO from applier from a given UUID.
Definition: rpl_channel_service_interface.cc:823
bool is_partial_transaction_on_channel_relay_log(const char *channel)
Checks if the given channel's relaylog contains a partial transaction.
Definition: rpl_channel_service_interface.cc:1163
int channel_is_applier_waiting(const char *channel)
Checks if the applier, and its workers when parallel applier is enabled, has already consumed all rel...
Definition: rpl_channel_service_interface.cc:967
bool unset_source_connection_auto_failover_on_all_channels()
Unset SOURCE_CONNECTION_AUTO_FAILOVER=0 on all channels.
Definition: rpl_channel_service_interface.cc:1397
bool channel_is_active(const char *channel, enum_channel_thread_types type)
Tells if the selected component of the channel is active or not.
Definition: rpl_channel_service_interface.cc:700
int initialize_channel_service_interface()
Initializes channel structures if needed.
Definition: rpl_channel_service_interface.cc:90
int channel_get_credentials(const char *channel, std::string &user, std::string &password)
Method to get the credentials configured for a channel.
Definition: rpl_channel_service_interface.cc:1078
enum_multi_threaded_workers_type
Know parallelization options that can be applied to channel appliers.
Definition: rpl_channel_service_interface.h:58
@ CHANNEL_MTS_PARALLEL_TYPE_LOGICAL_CLOCK
Definition: rpl_channel_service_interface.h:60
@ CHANNEL_MTS_PARALLEL_TYPE_DB_NAME
Definition: rpl_channel_service_interface.h:59
enum_channel_thread_types
The known types of channel threads.
Definition: rpl_channel_service_interface.h:123
@ CHANNEL_NO_THD
Definition: rpl_channel_service_interface.h:124
@ CHANNEL_RECEIVER_THREAD
Definition: rpl_channel_service_interface.h:125
@ CHANNEL_APPLIER_THREAD
Definition: rpl_channel_service_interface.h:126
Channel information to connect to a receiver.
Definition: rpl_channel_service_interface.h:143
int until_condition
Definition: rpl_channel_service_interface.h:144
char * view_id
Definition: rpl_channel_service_interface.h:146
char * gtid
Definition: rpl_channel_service_interface.h:145
Creation information for a channel.
Definition: rpl_channel_service_interface.h:87
char * compression_algorithm
Definition: rpl_channel_service_interface.h:107
char * hostname
Definition: rpl_channel_service_interface.h:89
int channel_mts_parallel_type
Definition: rpl_channel_service_interface.h:95
char * public_key_path
Definition: rpl_channel_service_interface.h:104
int sql_delay
Definition: rpl_channel_service_interface.h:100
bool m_allow_drop_write_set
Definition: rpl_channel_service_interface.h:112
int m_source_connection_auto_failover
Definition: rpl_channel_service_interface.h:110
unsigned int zstd_compression_level
Definition: rpl_channel_service_interface.h:108
int replicate_same_server_id
Definition: rpl_channel_service_interface.h:98
int connect_retry
Definition: rpl_channel_service_interface.h:101
int channel_mts_parallel_workers
Definition: rpl_channel_service_interface.h:96
enum_channel_type type
Definition: rpl_channel_service_interface.h:88
int port
Definition: rpl_channel_service_interface.h:90
char * user
Definition: rpl_channel_service_interface.h:91
int retry_count
Definition: rpl_channel_service_interface.h:102
bool preserve_relay_logs
Definition: rpl_channel_service_interface.h:103
int get_public_key
Definition: rpl_channel_service_interface.h:105
int channel_mta_checkpoint_group
Definition: rpl_channel_service_interface.h:97
bool m_ignore_write_set_memory_limit
Definition: rpl_channel_service_interface.h:111
char * password
Definition: rpl_channel_service_interface.h:92
int thd_tx_priority
Definition: rpl_channel_service_interface.h:99
Channel_ssl_info * ssl_info
Definition: rpl_channel_service_interface.h:93
int auto_position
Definition: rpl_channel_service_interface.h:94
SSL information to be used when creating a channel.
Definition: rpl_channel_service_interface.h:67
char * ssl_key
Definition: rpl_channel_service_interface.h:74
char * ssl_ca_file_name
Definition: rpl_channel_service_interface.h:69
char * ssl_crl_file_name
Definition: rpl_channel_service_interface.h:72
int use_ssl
Definition: rpl_channel_service_interface.h:68
int ssl_verify_server_cert
Definition: rpl_channel_service_interface.h:76
char * tls_ciphersuites
Definition: rpl_channel_service_interface.h:78
char * ssl_cipher
Definition: rpl_channel_service_interface.h:75
char * tls_version
Definition: rpl_channel_service_interface.h:77
char * ssl_cert_file_name
Definition: rpl_channel_service_interface.h:71
char * ssl_crl_directory
Definition: rpl_channel_service_interface.h:73
char * ssl_ca_directory
Definition: rpl_channel_service_interface.h:70
Definition: task.h:425