![]() |
MySQL 26.7.0
Source Code Documentation
|
Recovery system data structure. More...
#include <log0recv.h>
Classes | |
| struct | Encryption_Key |
| struct | Space |
| Every space has its own heap and pages that belong to it. More... | |
Public Types | |
| using | Pages = std::unordered_map< page_no_t, recv_addr_t *, std::hash< page_no_t >, std::equal_to< page_no_t > > |
| using | Missing_Ids = std::unordered_set< space_id_t > |
| using | Spaces = std::unordered_map< space_id_t, Space, std::hash< space_id_t >, std::equal_to< space_id_t > > |
| using | Encryption_Keys = std::vector< Encryption_Key > |
Public Attributes | |
| ib_mutex_t | mutex |
| mutex protecting the fields apply_log_recs, decrements of n_pages_to_recover, and the state field in each recv_addr struct More... | |
| ib_mutex_t | writer_mutex |
| mutex coordinating flushing between recv_writer_thread and the recovery thread. More... | |
| os_event_t | flush_start |
| event to activate page cleaner threads More... | |
| os_event_t | flush_end |
| event to signal that the page cleaner has finished the request More... | |
| buf_flush_t | flush_type |
| type of the flush request. More... | |
| bool | apply_log_recs |
| This is true when log rec application to pages is allowed; this flag tells the i/o-handler if it should do log record application. More... | |
| byte * | buf |
| Buffer for parsing log records. More... | |
| size_t | buf_len |
| Size of the parsing buffer. More... | |
| ulint | len |
| Amount of data in buf. More... | |
| lsn_t | parse_start_lsn |
| This is the lsn from which we were able to start parsing log records and adding them to the hash table; zero if a suitable start point not found yet. More... | |
| lsn_t | checkpoint_lsn |
| Checkpoint lsn that was used during recovery (read from file). More... | |
| lsn_t | scanned_lsn |
| The log data has been scanned up to this lsn. More... | |
| uint32_t | scanned_epoch_no |
| The log data has been scanned up to this epoch_no. More... | |
| ulint | recovered_offset |
| Start offset of non-parsed log records in buf. More... | |
| lsn_t | recovered_lsn |
| The log records have been parsed up to this lsn. More... | |
| lsn_t | previous_recovered_lsn |
| The previous value of recovered_lsn - before we parsed the last mtr. More... | |
| lsn_t | last_block_first_mtr_boundary {} |
| Tracks what should be the proper value of first_rec_group field in the header of the block to which recovered_lsn belongs. More... | |
| bool | found_corrupt_log |
| Set when finding a corrupt log block or record, or there is a log parsing buffer overflow. More... | |
| bool | is_cloned_db |
| Data directory has been recognized as cloned data directory. More... | |
| bool | is_meb_db |
| Data directory has been recognized as data directory from MEB. More... | |
| bool | dblwr_state |
| Doublewrite buffer state before MEB recovery starts. More... | |
| Spaces * | spaces |
| Hash table of pages, indexed by SpaceID. More... | |
| ut::Todo_counter | n_pages_to_recover |
| Number of unique unprocessed page ids in the spaces nested hash table. More... | |
| dblwr::recv::DBLWR * | dblwr |
| Doublewrite buffer pages, destroyed after recovery completes. More... | |
| MetadataRecover * | metadata_recover |
| We store and merge all table persistent data here during scanning redo logs. More... | |
| Encryption_Keys * | keys |
| Encryption Key information per tablespace ID. More... | |
| Missing_Ids | missing_ids |
| Tablespace IDs that were ignored during redo log apply. More... | |
| Missing_Ids | deleted |
| Tablespace IDs that were explicitly deleted. More... | |
| ut::unique_ptr< ib::redo::Redo_applier > | redo_applier |
| Redo log applier. More... | |
Recovery system data structure.
| using recv_sys_t::Encryption_Keys = std::vector<Encryption_Key> |
| using recv_sys_t::Missing_Ids = std::unordered_set<space_id_t> |
| using recv_sys_t::Pages = std::unordered_map<page_no_t, recv_addr_t *, std::hash<page_no_t>, std::equal_to<page_no_t> > |
| using recv_sys_t::Spaces = std::unordered_map<space_id_t, Space, std::hash<space_id_t>, std::equal_to<space_id_t> > |
| bool recv_sys_t::apply_log_recs |
This is true when log rec application to pages is allowed; this flag tells the i/o-handler if it should do log record application.
| byte* recv_sys_t::buf |
Buffer for parsing log records.
| size_t recv_sys_t::buf_len |
Size of the parsing buffer.
| lsn_t recv_sys_t::checkpoint_lsn |
Checkpoint lsn that was used during recovery (read from file).
| dblwr::recv::DBLWR* recv_sys_t::dblwr |
Doublewrite buffer pages, destroyed after recovery completes.
| bool recv_sys_t::dblwr_state |
Doublewrite buffer state before MEB recovery starts.
We restore to this state after MEB recovery completes and disable the doublewrite buffer during MEB recovery.
| Missing_Ids recv_sys_t::deleted |
Tablespace IDs that were explicitly deleted.
| os_event_t recv_sys_t::flush_end |
event to signal that the page cleaner has finished the request
| os_event_t recv_sys_t::flush_start |
event to activate page cleaner threads
| buf_flush_t recv_sys_t::flush_type |
type of the flush request.
BUF_FLUSH_LRU: flush end of LRU, keeping free blocks. BUF_FLUSH_LIST: flush all of blocks.
| bool recv_sys_t::found_corrupt_log |
Set when finding a corrupt log block or record, or there is a log parsing buffer overflow.
| bool recv_sys_t::is_cloned_db |
Data directory has been recognized as cloned data directory.
| bool recv_sys_t::is_meb_db |
Data directory has been recognized as data directory from MEB.
| Encryption_Keys* recv_sys_t::keys |
Encryption Key information per tablespace ID.
| lsn_t recv_sys_t::last_block_first_mtr_boundary {} |
Tracks what should be the proper value of first_rec_group field in the header of the block to which recovered_lsn belongs.
It might be also zero, in which case it means we do not know.
| ulint recv_sys_t::len |
Amount of data in buf.
| MetadataRecover* recv_sys_t::metadata_recover |
We store and merge all table persistent data here during scanning redo logs.
| Missing_Ids recv_sys_t::missing_ids |
Tablespace IDs that were ignored during redo log apply.
| ib_mutex_t recv_sys_t::mutex |
mutex protecting the fields apply_log_recs, decrements of n_pages_to_recover, and the state field in each recv_addr struct
| ut::Todo_counter recv_sys_t::n_pages_to_recover |
Number of unique unprocessed page ids in the spaces nested hash table.
Increments are done only from the main recovery thread before apply starts. Decrements are done from multiple threads during batch apply phase, and are protected by the recv_sys_t::mutex.
| lsn_t recv_sys_t::parse_start_lsn |
This is the lsn from which we were able to start parsing log records and adding them to the hash table; zero if a suitable start point not found yet.
| lsn_t recv_sys_t::previous_recovered_lsn |
The previous value of recovered_lsn - before we parsed the last mtr.
It is equal to recovered_lsn before we parsed any mtr. This is used to find moments in which recovered_lsn moves to the next block in which case we should update the last_block_first_mtr_boundary (described below).
| lsn_t recv_sys_t::recovered_lsn |
The log records have been parsed up to this lsn.
| ulint recv_sys_t::recovered_offset |
Start offset of non-parsed log records in buf.
| ut::unique_ptr<ib::redo::Redo_applier> recv_sys_t::redo_applier |
Redo log applier.
| uint32_t recv_sys_t::scanned_epoch_no |
The log data has been scanned up to this epoch_no.
| lsn_t recv_sys_t::scanned_lsn |
The log data has been scanned up to this lsn.
| Spaces* recv_sys_t::spaces |
Hash table of pages, indexed by SpaceID.
| ib_mutex_t recv_sys_t::writer_mutex |
mutex coordinating flushing between recv_writer_thread and the recovery thread.