My Project
|
#include <replication.h>
Public Attributes | |
uint32 | len |
int(* | transmit_start )(Binlog_transmit_param *param, const char *log_file, my_off_t log_pos) |
int(* | transmit_stop )(Binlog_transmit_param *param) |
int(* | reserve_header )(Binlog_transmit_param *param, unsigned char *header, unsigned long size, unsigned long *len) |
int(* | before_send_event )(Binlog_transmit_param *param, unsigned char *packet, unsigned long len, const char *log_file, my_off_t log_pos) |
int(* | after_send_event )(Binlog_transmit_param *param, const char *event_buf, unsigned long len, const char *skipped_log_file, my_off_t skipped_log_pos) |
int(* | after_reset_master )(Binlog_transmit_param *param) |
Observe and extends the binlog dumping thread.
This callback is called after resetting master status
This is called when executing the command RESET MASTER, and is used to reset status variables added by observers.
param | Observer common parameter |
0 | Sucess |
1 | Failure |
int(* Binlog_transmit_observer::after_send_event)(Binlog_transmit_param *param, const char *event_buf, unsigned long len, const char *skipped_log_file, my_off_t skipped_log_pos) |
This callback is called after an event packet is sent to the slave or is skipped.
param | Observer common parameter |
event_buf | Binlog event packet buffer sent |
len | length of the event packet buffer |
skipped_log_file | Binlog file name of the event that was skipped in the master. This is null if the position was not skipped |
skipped_log_pos | Binlog position of the event that was skipped in the master. 0 if not skipped |
0 | Sucess |
1 | Failure |
int(* Binlog_transmit_observer::before_send_event)(Binlog_transmit_param *param, unsigned char *packet, unsigned long len, const char *log_file, my_off_t log_pos) |
This callback is called before sending an event packet to slave
param | Observer common parameter |
packet | Binlog event packet to send |
len | Length of the event packet |
log_file | Binlog file name of the event packet to send |
log_pos | Binlog position of the event packet to send |
0 | Sucess |
1 | Failure |
int(* Binlog_transmit_observer::reserve_header)(Binlog_transmit_param *param, unsigned char *header, unsigned long size, unsigned long *len) |
This callback is called to reserve bytes in packet header for event transmission
This callback is called when resetting transmit packet header to reserve bytes for this observer in packet header.
The header buffer is allocated by the server code, and size is the size of the header buffer. Each observer can only reserve a maximum size of size in the header.
param | Observer common parameter |
header | Pointer of the header buffer |
size | Size of the header buffer |
len | Header length reserved by this observer |
0 | Sucess |
1 | Failure |
int(* Binlog_transmit_observer::transmit_start)(Binlog_transmit_param *param, const char *log_file, my_off_t log_pos) |
This callback is called when binlog dumping starts
param | Observer common parameter |
log_file | Binlog file name to transmit from |
log_pos | Binlog position to transmit from |
0 | Sucess |
1 | Failure |
int(* Binlog_transmit_observer::transmit_stop)(Binlog_transmit_param *param) |
This callback is called when binlog dumping stops
param | Observer common parameter |
0 | Sucess |
1 | Failure |