MySQL 9.0.0
Source Code Documentation
Arch_Page_Sys::Recovery Class Reference

Recovery system data structure for the archiver. More...

#include <arch0recv.h>

Public Member Functions

 Recovery (Arch_Page_Sys *page_sys, const char *dir_name)
 Constructor: Initialize members. More...
 
 ~Recovery ()=default
 Destructor: Close open file and free resources. More...
 
dberr_t init_dblwr ()
 Initialise the archiver's recovery system. More...
 
bool scan_for_groups ()
 Scan the archive directory and fetch all info related to group directories and its files. More...
 
void print ()
 Print information related to the archiver recovery system added for debugging purposes. More...
 
dberr_t recover ()
 Parse for group information and fill the group. More...
 
dberr_t load_archiver ()
 Load archiver with the related data and start tracking if required. More...
 
 Recovery (Recovery const &)=delete
 Disable copy construction. More...
 
Recoveryoperator= (Recovery const &)=delete
 Disable assignment. More...
 

Private Member Functions

void read_group_dirs (const std::string file_path)
 Read all the group directories and store information related to them required for parsing. More...
 
void read_group_files (const std::string dir_path, const std::string file_path)
 Read all the archived files belonging to a group and store information related to them required for parsing. More...
 

Private Attributes

std::string m_arch_dir_name
 Archive directory. More...
 
Arch_Page_Sysm_page_sys
 Global dirty page archive system. More...
 
Arch_Dblwr_Ctx m_dblwr_ctx {}
 Doublewrite buffer context. More...
 
Arch_Dir_Group_Info_Map m_dir_group_info_map {}
 Mapping of group directory names and group information related to the group. More...
 

Detailed Description

Recovery system data structure for the archiver.

Constructor & Destructor Documentation

◆ Recovery() [1/2]

Arch_Page_Sys::Recovery::Recovery ( Arch_Page_Sys page_sys,
const char *  dir_name 
)
inline

Constructor: Initialize members.

Parameters
[in,out]page_sysglobal dirty page archive system
[in]dir_namemain archiver directory name

◆ ~Recovery()

Arch_Page_Sys::Recovery::~Recovery ( )
default

Destructor: Close open file and free resources.

◆ Recovery() [2/2]

Arch_Page_Sys::Recovery::Recovery ( Recovery const &  )
delete

Disable copy construction.

Member Function Documentation

◆ init_dblwr()

dberr_t Arch_Page_Sys::Recovery::init_dblwr ( )

Initialise the archiver's recovery system.

Returns
error code.

◆ load_archiver()

dberr_t Arch_Page_Sys::Recovery::load_archiver ( )

Load archiver with the related data and start tracking if required.

Returns
error code.

◆ operator=()

Recovery & Arch_Page_Sys::Recovery::operator= ( Recovery const &  )
delete

Disable assignment.

◆ print()

void Arch_Page_Sys::Recovery::print ( )

Print information related to the archiver recovery system added for debugging purposes.

◆ read_group_dirs()

void Arch_Page_Sys::Recovery::read_group_dirs ( const std::string  file_path)
private

Read all the group directories and store information related to them required for parsing.

Parameters
[in]file_pathfile path information

◆ read_group_files()

void Arch_Page_Sys::Recovery::read_group_files ( const std::string  dir_path,
const std::string  file_path 
)
private

Read all the archived files belonging to a group and store information related to them required for parsing.

Parameters
[in]dir_pathdir path information
[in]file_pathfile path information

◆ recover()

dberr_t Arch_Page_Sys::Recovery::recover ( )

Parse for group information and fill the group.

Returns
error code.

◆ scan_for_groups()

bool Arch_Page_Sys::Recovery::scan_for_groups ( )

Scan the archive directory and fetch all info related to group directories and its files.

Returns
true if the scan was successful.

Member Data Documentation

◆ m_arch_dir_name

std::string Arch_Page_Sys::Recovery::m_arch_dir_name
private

Archive directory.

◆ m_dblwr_ctx

Arch_Dblwr_Ctx Arch_Page_Sys::Recovery::m_dblwr_ctx {}
private

Doublewrite buffer context.

◆ m_dir_group_info_map

Arch_Dir_Group_Info_Map Arch_Page_Sys::Recovery::m_dir_group_info_map {}
private

Mapping of group directory names and group information related to the group.

◆ m_page_sys

Arch_Page_Sys* Arch_Page_Sys::Recovery::m_page_sys
private

Global dirty page archive system.


The documentation for this class was generated from the following files: