49#define COMPACT_FLAG 0x01
50#define VERSION_FLAG 0x02
51#define INSTANT_FLAG 0x04
53#define IS_INSTANT(flags) (flags & INSTANT_FLAG)
54#define IS_VERSIONED(flags) (flags & VERSION_FLAG)
55#define IS_COMPACT(flags) (flags & COMPACT_FLAG)
57#define SET_INSTANT(flags) (flag |= INSTANT_FLAG)
58#define SET_VERSIONED(flags) (flag |= VERSION_FLAG)
59#define SET_COMPACT(flags) (flag |= COMPACT_FLAG)
179#ifndef UNIV_HOTBACKUP
194#define mlog_write_initial_log_record(ptr, type, mtr) ((void)0)
195#define mlog_write_initial_log_record_fast(ptr, type, log_ptr, mtr) \
251 size_t size,
byte *&log_ptr);
uint32_t space_id_t
Tablespace identifier.
Definition: api0api.h:48
uint32_t page_no_t
Page number.
Definition: api0api.h:46
int page
Definition: ctype-mb.cc:1234
ib_id_t table_id_t
Table or partition identifier (unique within an InnoDB instance).
Definition: dict0types.h:232
The dynamically allocated buffer implementation.
static bool mlog_open_metadata(mtr_t *mtr, ulint size, byte *&buffer)
Opens a buffer to mlog.
static void mlog_catenate_ulint(mtr_buf_t *dyn_buf, ulint val, mlog_id_t type)
Catenates 1 - 4 bytes to the mtr log.
constexpr uint8_t INDEX_LOG_VERSION_0
Definition: mtr0log.h:45
constexpr uint8_t INDEX_LOG_VERSION_CURRENT
Definition: mtr0log.h:46
constexpr size_t REDO_LOG_INITIAL_INFO_SIZE
Definition: mtr0log.h:65
const byte * mlog_parse_nbytes(mlog_id_t type, const byte *ptr, const byte *end_ptr, byte *page, void *page_zip)
Parses a log record written by mlog_write_ulint or mlog_write_ull.
Definition: mtr0log.cc:165
void mlog_log_string(byte *ptr, ulint len, mtr_t *mtr)
Logs a write of a string to a file page buffered in the buffer pool.
Definition: mtr0log.cc:347
const byte * mlog_parse_string(const byte *ptr, const byte *end_ptr, byte *page, void *page_zip)
Parses a log record written by mlog_write_string.
Definition: mtr0log.cc:377
void mlog_catenate_string(mtr_t *mtr, const byte *str, ulint len)
Catenates n bytes to the mtr log.
Definition: mtr0log.cc:61
static byte * mlog_write_initial_log_record_fast(const byte *ptr, mlog_id_t type, byte *log_ptr, mtr_t *mtr)
Writes the initial part of a log record (3..11 bytes).
const byte * mlog_parse_initial_log_record(const byte *ptr, const byte *end_ptr, mlog_id_t *type, space_id_t *space, page_no_t *page_no)
Parses an initial log record written by mlog_write_initial_log_record.
Definition: mtr0log.cc:134
constexpr auto MLOG_BUF_MARGIN
Insert, update, and maybe other functions may use this value to define an extra mlog buffer size for ...
Definition: mtr0log.h:274
static bool mlog_open(mtr_t *mtr, ulint size, byte *&buffer)
Opens a buffer to mlog.
static void mlog_catenate_ull_compressed(mtr_t *mtr, uint64_t val)
Catenates a compressed 64-bit integer to mlog.
static void mlog_catenate_ulint_compressed(mtr_t *mtr, ulint val)
Catenates a compressed ulint to mlog.
const byte * mlog_parse_index(const byte *ptr, const byte *end_ptr, dict_index_t **index)
Parses a log record written by mlog_open_and_write_index.
Definition: mtr0log.cc:1224
const byte * mlog_parse_index_8027(const byte *ptr, const byte *end_ptr, bool comp, dict_index_t **index)
Parses a log record written by mlog_open_and_write_index in version <= 8027.
Definition: mtr0log.cc:419
void mlog_write_ulint(byte *ptr, ulint val, mlog_id_t type, mtr_t *mtr)
Writes 1, 2 or 4 bytes to a file page.
Definition: mtr0log.cc:258
bool mlog_open_and_write_index(mtr_t *mtr, const byte *rec, const dict_index_t *index, mlog_id_t type, size_t size, byte *&log_ptr)
Opens a buffer for mlog, writes the initial log record and, if needed, the field lengths of an index.
Definition: mtr0log.cc:800
void mlog_write_string(byte *ptr, const byte *str, ulint len, mtr_t *mtr)
Writes a string to a file page buffered in the buffer pool.
Definition: mtr0log.cc:329
void mlog_write_initial_log_record(const byte *ptr, mlog_id_t type, mtr_t *mtr)
Writes initial part of a log record consisting of one-byte item type and four-byte space and page num...
Definition: mtr0log.cc:73
void mlog_write_ull(byte *ptr, uint64_t val, mtr_t *mtr)
Writes 8 bytes to a file page.
Definition: mtr0log.cc:300
static byte * mlog_write_initial_dict_log_record(mlog_id_t type, table_id_t id, uint64_t version, byte *log_ptr, mtr_t *mtr)
Writes a log record about a dictionary operation, which would cost at most 23 bytes.
static void mlog_close(mtr_t *mtr, byte *ptr)
Closes a buffer opened to mlog.
static byte * mlog_write_initial_log_record_low(mlog_id_t type, space_id_t space_id, page_no_t page_no, byte *log_ptr, mtr_t *mtr)
Writes a log record about an operation.
constexpr uint8_t INDEX_LOG_VERSION_MAX
Definition: mtr0log.h:47
const byte * mlog_parse_initial_dict_log_record(const byte *ptr, const byte *end_ptr, mlog_id_t *type, table_id_t *id, uint64_t *version)
Parses an initial log record written by mlog_write_initial_dict_log_record.
Definition: mtr0log.cc:104
Mini-transaction logging routines.
mlog_id_t
Definition: mtr0types.h:63
std::string str(const mysqlrouter::ConfigGenerator::Options::Endpoint &ep)
Definition: config_generator.cc:1081
size_t size(const char *const c)
Definition: base64.h:46
mutable_buffer buffer(void *p, size_t n) noexcept
Definition: buffer.h:418
required uint64 version
Definition: replication_group_member_actions.proto:41
required string type
Definition: replication_group_member_actions.proto:34
Data structure for an index.
Definition: dict0mem.h:1046
space_id_t space_id() const
Get the space id of the tablespace to which this index belongs.
Definition: dict0mem.h:1634
unsigned space
space where the index tree is placed
Definition: dict0mem.h:1063
Mini-transaction handle and buffer.
Definition: mtr0mtr.h:177
Version control for database, common definitions, and include files.
unsigned long int ulint
Definition: univ.i:406