MySQL 8.4.3
Source Code Documentation
|
Auxiliary class to copy serialized events to the binary log and correct some of the fields that are not known until just before writing the event. More...
Public Member Functions | |
Binlog_event_writer (MYSQL_BIN_LOG::Binlog_ofile *binlog_file) | |
Constructs a new Binlog_event_writer. More... | |
void | update_header () |
bool | write (const unsigned char *buffer, my_off_t length) override |
Write some bytes into the output stream. More... | |
bool | is_checksum_enabled () |
Returns true if per event checksum is enabled. More... | |
Public Member Functions inherited from Basic_ostream | |
virtual | ~Basic_ostream ()=default |
Private Attributes | |
MYSQL_BIN_LOG::Binlog_ofile * | m_binlog_file |
bool | have_checksum |
ha_checksum | initial_checksum |
ha_checksum | checksum |
uint32 | end_log_pos |
uchar | header [LOG_EVENT_HEADER_LEN] |
my_off_t | header_len = 0 |
uint32 | event_len = 0 |
Auxiliary class to copy serialized events to the binary log and correct some of the fields that are not known until just before writing the event.
This class allows feeding events in parts, so it is practical to use in do_write_cache() which reads events from an IO_CACHE where events may span multiple cache pages.
The following fields are fixed before writing the event:
|
inline |
Constructs a new Binlog_event_writer.
Should be called once before starting to flush the transaction or statement cache to the binlog.
binlog_file | to write to. |
|
inline |
Returns true if per event checksum is enabled.
|
inline |
|
inlineoverridevirtual |
Write some bytes into the output stream.
When all data is written into the stream successfully, then it return false. Otherwise, true is returned. It will never returns false when partial data is written into the stream.
[in] | buffer | Data to be written |
[in] | length | Length of the data |
false | Success. |
true | Error. |
Implements Basic_ostream.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |