33#ifndef MYSQL_BINLOG_EVENT_TRX_BOUNDARY_PARSER_H
34#define MYSQL_BINLOG_EVENT_TRX_BOUNDARY_PARSER_H
143 bool throw_warnings);
276 bool throw_warnings);
289 bool throw_warnings);
This is the base class for verifying transaction boundaries.
Definition: trx_boundary_parser.h:50
enum_event_parser_state
Definition: trx_boundary_parser.h:231
@ EVENT_PARSER_DDL
Definition: trx_boundary_parser.h:237
@ EVENT_PARSER_DML
Definition: trx_boundary_parser.h:239
@ EVENT_PARSER_GTID
Definition: trx_boundary_parser.h:235
@ EVENT_PARSER_NONE
Definition: trx_boundary_parser.h:233
@ EVENT_PARSER_ERROR
Definition: trx_boundary_parser.h:241
bool is_not_inside_transaction()
State if the transaction boundary parser is not inside a transaction.
Definition: trx_boundary_parser.h:112
enum_event_parser_state last_parser_state
Last internal state of the event parser.
Definition: trx_boundary_parser.h:254
void reset()
Reset the transaction boundary parser state.
Definition: trx_boundary_parser.cpp:54
void rollback()
Rolls back to the last parser state.
Definition: trx_boundary_parser.h:163
enum_event_boundary_type m_current_boundary_state
The last processed boundary event type.
Definition: trx_boundary_parser.h:259
bool feed_event(mysql::binlog::event::Log_event_basic_info log_event_info, bool throw_warnings)
Feed the transaction boundary parser with a Log_event of any type in object type.
Definition: trx_boundary_parser.cpp:64
virtual ~Transaction_boundary_parser()
Destructor.
bool check_row_logging_constraints(mysql::binlog::event::Log_event_basic_info event_info)
Evaluate given the current info about boundary type, event type and parser state if the given event v...
Definition: trx_boundary_parser.cpp:74
enum_event_boundary_type get_event_boundary_type(mysql::binlog::event::Log_event_basic_info event_info, bool throw_warnings)
Parses an raw event based on the event parser logic.
Definition: trx_boundary_parser.cpp:140
bool is_inside_transaction()
State if the transaction boundary parser is inside a transaction.
Definition: trx_boundary_parser.h:99
enum_trx_boundary_parser_context
The context where the parser is used.
Definition: trx_boundary_parser.h:55
@ TRX_BOUNDARY_PARSER_APPLIER
Definition: trx_boundary_parser.h:59
@ TRX_BOUNDARY_PARSER_RECEIVER
Definition: trx_boundary_parser.h:57
enum_event_boundary_type
Definition: trx_boundary_parser.h:182
@ EVENT_BOUNDARY_TYPE_END_TRX
Definition: trx_boundary_parser.h:190
@ EVENT_BOUNDARY_TYPE_ERROR
Definition: trx_boundary_parser.h:183
@ EVENT_BOUNDARY_TYPE_INCIDENT
Definition: trx_boundary_parser.h:201
@ EVENT_BOUNDARY_TYPE_STATEMENT
Definition: trx_boundary_parser.h:199
@ EVENT_BOUNDARY_TYPE_TRANSACTION_PAYLOAD
Definition: trx_boundary_parser.h:210
@ EVENT_BOUNDARY_TYPE_IGNORE
Definition: trx_boundary_parser.h:206
@ EVENT_BOUNDARY_TYPE_GTID
Definition: trx_boundary_parser.h:185
@ EVENT_BOUNDARY_TYPE_PRE_STATEMENT
Definition: trx_boundary_parser.h:194
@ EVENT_BOUNDARY_TYPE_BEGIN_TRX
Definition: trx_boundary_parser.h:187
@ EVENT_BOUNDARY_TYPE_END_XA_TRX
Definition: trx_boundary_parser.h:192
enum_event_parser_error
Internal error indentifiers for parser issues.
Definition: trx_boundary_parser.h:168
@ ER_TRX_BOUND_UNEXPECTED_COMMIT_ROLLBACK_OR_XID_LOG_EVENT_IN_STREAM
Definition: trx_boundary_parser.h:176
@ ER_TRX_BOUND_GTID_LOG_EVENT_IN_STREAM
Definition: trx_boundary_parser.h:172
@ ER_TRX_BOUND_UNEXPECTED_BEGIN_IN_STREAM
Definition: trx_boundary_parser.h:174
@ ER_TRX_BOUND_UNEXPECTED_XA_ROLLBACK_IN_STREAM
Definition: trx_boundary_parser.h:178
@ ER_TRX_BOUND_UNSUPPORTED_UNIGNORABLE_EVENT_IN_STREAM
Definition: trx_boundary_parser.h:170
enum_trx_boundary_parser_context m_trx_boundary_parser_context
In which context of the boundary parser is used.
Definition: trx_boundary_parser.h:264
bool is_error()
State if the transaction boundary parser was fed with a sequence of events that the parser wasn't abl...
Definition: trx_boundary_parser.h:123
Transaction_boundary_parser(enum_trx_boundary_parser_context context)
Constructor.
Definition: trx_boundary_parser.h:66
enum_event_parser_state current_parser_state
Current internal state of the event parser.
Definition: trx_boundary_parser.h:247
bool update_state(enum_event_boundary_type event_boundary_type, bool throw_warnings)
Set the boundary parser state based on the event parser logic.
Definition: trx_boundary_parser.cpp:293
virtual void log_server_warning(int error, const char *message)
Log warnings using some defined logging interface.
Definition: trx_boundary_parser.cpp:530
Contains the classes representing events operating in the replication stream properties.
The namespace contains classes representing events that can occur in a replication stream.
Definition: binlog_event.cpp:36
Struct to pass basic information about a event: type, query, is it ignorable.
Definition: binlog_event.h:407