52 size_t reserved_bytes_per_thread)
override;
67 Lsn &end_lsn)
override;
89 size_t data_len)
const override;
117[[nodiscard]]
inline Handler_interface::Capabilities
Definition: ha0sys_var_handler_interface.h:36
This Redo Log Handler interface provides an abstraction over the redo log persistence and publishing ...
Definition: log0handler_interface.h:42
Durability
Used by persist_smaller_than(...desired_guarantee) to let the caller specify the desired guarantee ab...
Definition: log0handler_interface.h:602
Origin
Used by persist_smaller_than(...origin) and persist_available(...origin) to let the caller specify th...
Definition: log0handler_interface.h:591
std::array< unsigned char, METADATA_BLOCK_SIZE > Metadata_value
Definition: log0handler_interface.h:785
Definition: log0handler.h:41
bool update_free_check_limit()
Recomputes log_sys->m_free_check_limit_lsn.
Definition: log0handler.cc:626
Capabilities get_capabilities() override
Query the capabilities of the Redo Log Handler.
Definition: log0handler.h:118
Status start_reading() override
Informs the Redo Log Handler that InnoDB intends to start reading from the log.
Definition: log0handler.cc:155
Status persist_smaller_than(Lsn end_lsn, Durability desired_guarantee, Origin origin) override
A synchronous request for the Redo Log Handler to promise that previously written data is durable at ...
Definition: log0handler.cc:290
bool reconfigure(size_t max_threads, size_t reserved_bytes_per_thread) override
InnoDB uses write_mtr(data,..) in mtr.commit() when a thread still holds latches on pages involved in...
Definition: log0handler.cc:683
Status do_not_need_smaller_than(Lsn needed_lsn) override
Definition: log0handler.cc:677
void stop_writing() override
Informs Redo Log Handler that the caller no longer intends writing to the log.
Definition: log0handler.cc:288
size_t m_reserved_bytes_per_thread
The value of reserved_bytes_per_thread most recently passed to reconfigure.
Definition: log0handler.h:102
Status start_writing(Lsn lsn) override
Informs Redo Log Handler that the caller intends to start writing to the log.
Definition: log0handler.cc:276
void wait_for_space() override
Called from a thread which wishes to pass no more than reserved_bytes_per_thread of data to write_mtr...
Definition: log0handler.cc:741
Status persist_available(const Origin &origin) override
Similar to persist_smaller_than(end_lsn, origin), except that the caller politely asks the Redo Log H...
Definition: log0handler.cc:522
Lsn compute_end_lsn(Lsn start_lsn, size_t data_len) const override
Returns the lsn at the requested position that is the end of the MTR data.
Definition: log0handler.cc:307
Sys_var_handler m_sys_var_handler
Definition: log0handler.h:95
size_t m_max_threads
The value of max_threads most recently passed to reconfigure.
Definition: log0handler.h:98
bool has_space() override
This is a no-wait variant of wait_for_space(), i.e.
Definition: log0handler.cc:777
Lsn align_down_to_known_boundary(Lsn lsn) override
Each call to write_mtr(..., &start_lsn, &end_lsn), or create(start_lsn), declares start_lsn to be a b...
Definition: log0handler.cc:311
Lsn peek_first_nonpersisted_lsn() override
Intuitively returns the largest end_lsn passed to a successfully finished persist_smaller_than(end_ls...
Definition: log0handler.cc:518
Status read(Lsn start_lsn, Buffer &buffer) override
Reads previously persisted portion of the Log starting from start_lsn synchronously.
Definition: log0handler.cc:379
~Handler() override
Definition: log0handler.cc:153
Status create(Lsn start_lsn) override
Request synchronous creation of Log starting at a given start_lsn.
Definition: log0handler.cc:186
Capacity_estimate get_capacity_estimate() override
Used by InnoDB to determine if page cleaning and checkpointing should be speed up,...
Definition: log0handler.cc:612
Lsn peek_first_unassigned_lsn() override
Intuitively returns the largest end_lsn assigned from an write_mtr(..,&end_lsn) call.
Definition: log0handler.cc:517
Sys_var_handler_interface & config_handler() override
Returns the handler to configure the redo log related system variables.
Definition: log0handler.cc:784
Status store_metadata(uint16_t key, const Metadata_value &value) override
Persists synchronously the metadata atomically overwriting the old value for a given key.
Definition: log0handler.cc:528
Status get_metadata(uint16_t key, Metadata_value &metadata) override
Retrieves the previously stored metadata block for a given key.
Definition: log0handler.cc:788
Status write_mtr(const Const_buffers &mtr_data, Lsn &start_lsn, Lsn &end_lsn) override
Request an asynchronous append of the mtr's body's bytes to the log.
Definition: log0handler.cc:208
This class implements the handling of redo log related system variables.
Definition: log0sys_var_handler.h:37
void log_track_changes_of_recovered_lsn(ib::redo::Lsn old_recovered_lsn, ib::redo::Lsn new_recovered_lsn, ib::redo::Lsn &last_block_first_mtr_boundary)
Tracks changes of recovered_lsn and tracks proper values for what first_rec_group should be for conse...
Definition: log0handler.cc:1518
Definition: log0common.h:32
Status
Additional error constants may be added to the list here, keeping in mind the following guidelines ab...
Definition: log0common.h:102
uint64_t Lsn
Definition: log0common.h:60
Metadata_key
The type of metadata that could be handled by the handler.
Definition: log0handler.h:36
@ HEADER
Definition: log0handler.h:36
@ CHECKPOINT
Definition: log0handler.h:36
std::span< uint8_t > Buffer
Definition: log0common.h:123
ValueType value(const std::optional< ValueType > &v)
Definition: gtid.h:83
mutable_buffer buffer(void *p, size_t n) noexcept
Definition: buffer.h:418
required string key
Definition: replication_asynchronous_connection_failover.proto:60
Definition: log0common.h:125
Definition: log0handler_interface.h:56
bool atomic_write
If true, then the implementation supports "atomic writes", which means that if any of the bytes passe...
Definition: log0handler_interface.h:71
bool supports_encryption
True if REDO log encryption is supported.
Definition: log0handler_interface.h:79
bool supports_disabling
Is ALTER INSTANCE DISABLE INNODB REDO_LOG supported?
Definition: log0handler_interface.h:77
bool supports_meb
MEB assumes direct access to files in specific location and format.
Definition: log0handler_interface.h:75
bool supports_clone
CLONE assumes direct access to files in specific location and format.
Definition: log0handler_interface.h:73
Describes the state of the capacity in sufficient detail that InnoDB knows if it should rush with pag...
Definition: log0handler_interface.h:256
Version control for database, common definitions, and include files.
static uint64_t lsn
Definition: xcom_base.cc:446