32#ifndef MYSQL_BINLOG_EVENT_TRX_BOUNDARY_PARSER_H
33#define MYSQL_BINLOG_EVENT_TRX_BOUNDARY_PARSER_H
142 bool throw_warnings);
275 bool throw_warnings);
288 bool throw_warnings);
This is the base class for verifying transaction boundaries.
Definition: trx_boundary_parser.h:49
enum_event_parser_state
Definition: trx_boundary_parser.h:230
@ EVENT_PARSER_DDL
Definition: trx_boundary_parser.h:236
@ EVENT_PARSER_DML
Definition: trx_boundary_parser.h:238
@ EVENT_PARSER_GTID
Definition: trx_boundary_parser.h:234
@ EVENT_PARSER_NONE
Definition: trx_boundary_parser.h:232
@ EVENT_PARSER_ERROR
Definition: trx_boundary_parser.h:240
bool is_not_inside_transaction()
State if the transaction boundary parser is not inside a transaction.
Definition: trx_boundary_parser.h:111
enum_event_parser_state last_parser_state
Last internal state of the event parser.
Definition: trx_boundary_parser.h:253
void reset()
Reset the transaction boundary parser state.
Definition: trx_boundary_parser.cpp:53
void rollback()
Rolls back to the last parser state.
Definition: trx_boundary_parser.h:162
enum_event_boundary_type m_current_boundary_state
The last processed boundary event type.
Definition: trx_boundary_parser.h:258
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:63
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:73
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:145
bool is_inside_transaction()
State if the transaction boundary parser is inside a transaction.
Definition: trx_boundary_parser.h:98
enum_trx_boundary_parser_context
The context where the parser is used.
Definition: trx_boundary_parser.h:54
@ TRX_BOUNDARY_PARSER_APPLIER
Definition: trx_boundary_parser.h:58
@ TRX_BOUNDARY_PARSER_RECEIVER
Definition: trx_boundary_parser.h:56
enum_event_boundary_type
Definition: trx_boundary_parser.h:181
@ EVENT_BOUNDARY_TYPE_END_TRX
Definition: trx_boundary_parser.h:189
@ EVENT_BOUNDARY_TYPE_ERROR
Definition: trx_boundary_parser.h:182
@ EVENT_BOUNDARY_TYPE_INCIDENT
Definition: trx_boundary_parser.h:200
@ EVENT_BOUNDARY_TYPE_STATEMENT
Definition: trx_boundary_parser.h:198
@ EVENT_BOUNDARY_TYPE_TRANSACTION_PAYLOAD
Definition: trx_boundary_parser.h:209
@ EVENT_BOUNDARY_TYPE_IGNORE
Definition: trx_boundary_parser.h:205
@ EVENT_BOUNDARY_TYPE_GTID
Definition: trx_boundary_parser.h:184
@ EVENT_BOUNDARY_TYPE_PRE_STATEMENT
Definition: trx_boundary_parser.h:193
@ EVENT_BOUNDARY_TYPE_BEGIN_TRX
Definition: trx_boundary_parser.h:186
@ EVENT_BOUNDARY_TYPE_END_XA_TRX
Definition: trx_boundary_parser.h:191
enum_event_parser_error
Internal error indentifiers for parser issues.
Definition: trx_boundary_parser.h:167
@ ER_TRX_BOUND_UNEXPECTED_COMMIT_ROLLBACK_OR_XID_LOG_EVENT_IN_STREAM
Definition: trx_boundary_parser.h:175
@ ER_TRX_BOUND_GTID_LOG_EVENT_IN_STREAM
Definition: trx_boundary_parser.h:171
@ ER_TRX_BOUND_UNEXPECTED_BEGIN_IN_STREAM
Definition: trx_boundary_parser.h:173
@ ER_TRX_BOUND_UNEXPECTED_XA_ROLLBACK_IN_STREAM
Definition: trx_boundary_parser.h:177
@ ER_TRX_BOUND_UNSUPPORTED_UNIGNORABLE_EVENT_IN_STREAM
Definition: trx_boundary_parser.h:169
enum_trx_boundary_parser_context m_trx_boundary_parser_context
In which context of the boundary parser is used.
Definition: trx_boundary_parser.h:263
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:122
Transaction_boundary_parser(enum_trx_boundary_parser_context context)
Constructor.
Definition: trx_boundary_parser.h:65
enum_event_parser_state current_parser_state
Current internal state of the event parser.
Definition: trx_boundary_parser.h:246
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:301
virtual void log_server_warning(int error, const char *message)
Log warnings using some defined logging interface.
Definition: trx_boundary_parser.cpp:538
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:35
Struct to pass basic information about a event: type, query, is it ignorable.
Definition: binlog_event.h:405