MySQL 9.1.0
Source Code Documentation
|
Innodb clone descriptors. More...
Functions | |
uint | choose_desc_version (const byte *ref_loc) |
Choose lowest descriptor version between reference locator and currently supported version. More... | |
bool | clone_validate_locator (const byte *desc_loc, uint desc_len) |
Check if clone locator is valid. More... | |
bool | DESC_CHECK_FLAG (ulint flag, ulint bit) |
Check a specific bit in flag. More... | |
void | DESC_SET_FLAG (ulint &flag, ulint bit) |
Set a specific bit in flag. More... | |
Variables | |
static const uint | CLONE_DESC_MAX_VERSION = 100 |
Maximum supported descriptor version. More... | |
static const uint | CLONE_DESC_VER_OFFSET = 0 |
Header: Version is in first 4 bytes. More... | |
static const uint | CLONE_DESC_LEN_OFFSET = CLONE_DESC_VER_OFFSET + 4 |
Header: Total length is stored in next 4 bytes. More... | |
static const uint | CLONE_DESC_TYPE_OFFSET = CLONE_DESC_LEN_OFFSET + 4 |
Header: Descriptor type is in next 4 bytes. More... | |
static const uint | CLONE_DESC_HEADER_LEN = CLONE_DESC_TYPE_OFFSET + 4 |
Header: Fixed length. More... | |
static const uint | CLONE_TASK_INDEX_OFFSET = CLONE_DESC_HEADER_LEN |
Task: Clone task index in 4 bytes. More... | |
static const uint | CLONE_TASK_CHUNK_OFFSET = CLONE_TASK_INDEX_OFFSET + 4 |
Task: Task chunk number in 4 bytes. More... | |
static const uint | CLONE_TASK_BLOCK_OFFSET = CLONE_TASK_CHUNK_OFFSET + 4 |
Task: Task block number in 4 bytes. More... | |
static const uint | CLONE_TASK_META_LEN = CLONE_TASK_BLOCK_OFFSET + 4 |
Task: Total length. More... | |
static const uint | CLONE_LOC_CID_OFFSET = CLONE_DESC_HEADER_LEN |
Locator: Clone identifier in 8 bytes. More... | |
static const uint | CLONE_LOC_SID_OFFSET = CLONE_LOC_CID_OFFSET + 8 |
Locator: Snapshot identifier in 8 bytes. More... | |
static const uint | CLONE_LOC_IDX_OFFSET = CLONE_LOC_SID_OFFSET + 8 |
Locator: Clone array index in 4 bytes. More... | |
static const uint | CLONE_LOC_STATE_OFFSET = CLONE_LOC_IDX_OFFSET + 4 |
Locator: Clone Snapshot state in 1 byte. More... | |
static const uint | CLONE_LOC_META_OFFSET = CLONE_LOC_STATE_OFFSET + 1 |
Locator: Clone Snapshot sub-state in 1 byte. More... | |
static const uint | CLONE_DESC_LOC_BASE_LEN = CLONE_LOC_META_OFFSET + 1 |
Locator: Total length. More... | |
static const uint | CLONE_FILE_STATE_OFFSET = CLONE_DESC_HEADER_LEN |
File Metadata: Snapshot state in 4 bytes. More... | |
static const uint | CLONE_FILE_SIZE_OFFSET = CLONE_FILE_STATE_OFFSET + 4 |
File Metadata: File size in 8 bytes. More... | |
static const uint | CLONE_FILE_ALLOC_SIZE_OFFSET = CLONE_FILE_SIZE_OFFSET + 8 |
File Metadata: Sparse file allocation size on disk in 8 bytes. More... | |
static const uint | CLONE_FILE_FSP_OFFSET = CLONE_FILE_ALLOC_SIZE_OFFSET + 8 |
File Metadata: FSP flags in 4 bytes. More... | |
static const uint | CLONE_FILE_FSBLK_OFFSET = CLONE_FILE_FSP_OFFSET + 4 |
File Metadata: File system block size for compressed tables in 4 bytes. More... | |
static const uint | CLONE_FILE_FLAGS_OFFSET = CLONE_FILE_FSBLK_OFFSET + 4 |
File Metadata: File space flags in next 2 bytes [Maximum 16 flags]. More... | |
static const uint | CLONE_DESC_FILE_FLAG_ZLIB = 1 |
Clone File Flag: Compression type ZLIB. More... | |
static const uint | CLONE_DESC_FILE_FLAG_LZ4 = 2 |
Clone File Flag: Compression type LZ4. More... | |
static const uint | CLONE_DESC_FILE_FLAG_AES = 3 |
Clone File Flag: Encryption type AES. More... | |
static const uint | CLONE_DESC_FILE_FLAG_RENAMED = 4 |
Clone File Flag: File is renamed. More... | |
static const uint | CLONE_DESC_FILE_FLAG_DELETED = 5 |
Clone File Flag: File is deleted. More... | |
static const uint | CLONE_DESC_FILE_HAS_KEY = 6 |
Clone File Flag: File metadata has encryption key. More... | |
static const uint | CLONE_FILE_SPACE_ID_OFFSET = CLONE_FILE_FLAGS_OFFSET + 2 |
File Metadata: Tablespace ID in 4 bytes. More... | |
static const uint | CLONE_FILE_IDX_OFFSET = CLONE_FILE_SPACE_ID_OFFSET + 4 |
File Metadata: File index in 4 bytes. More... | |
static const uint | CLONE_FILE_BCHUNK_OFFSET = CLONE_FILE_IDX_OFFSET + 4 |
File Metadata: First chunk number in 4 bytes. More... | |
static const uint | CLONE_FILE_ECHUNK_OFFSET = CLONE_FILE_BCHUNK_OFFSET + 4 |
File Metadata: Last chunk number in 4 bytes. More... | |
static const uint | CLONE_FILE_FNAMEL_OFFSET = CLONE_FILE_ECHUNK_OFFSET + 4 |
File Metadata: File name length in 4 bytes. More... | |
static const uint | CLONE_FILE_FNAME_OFFSET = CLONE_FILE_FNAMEL_OFFSET + 4 |
File Metadata: File name. More... | |
static const uint | CLONE_FILE_BASE_LEN = CLONE_FILE_FNAME_OFFSET |
File Metadata: Length excluding the file name. More... | |
static const uint | CLONE_DESC_STATE_OFFSET = CLONE_DESC_HEADER_LEN |
Clone State: Snapshot state in 4 bytes. More... | |
static const uint | CLONE_DESC_TASK_OFFSET = CLONE_DESC_STATE_OFFSET + 4 |
Clone State: Task index in 4 bytes. More... | |
static const uint | CLONE_DESC_STATE_NUM_CHUNKS = CLONE_DESC_TASK_OFFSET + 4 |
Clone State: Number of chunks in 4 bytes. More... | |
static const uint | CLONE_DESC_STATE_NUM_FILES = CLONE_DESC_STATE_NUM_CHUNKS + 4 |
Clone State: Number of files in 4 bytes. More... | |
static const uint | CLONE_DESC_STATE_EST_BYTES = CLONE_DESC_STATE_NUM_FILES + 4 |
Clone State: Estimated number of bytes in 8 bytes. More... | |
static const uint | CLONE_DESC_STATE_EST_DISK = CLONE_DESC_STATE_EST_BYTES + 8 |
Clone State: Estimated number of bytes in 8 bytes. More... | |
static const uint | CLONE_DESC_STATE_FLAGS = CLONE_DESC_STATE_EST_DISK + 8 |
Clone State: flags in 2 byte [max 16 flags]. More... | |
static const uint | CLONE_DESC_STATE_LEN = CLONE_DESC_STATE_FLAGS + 2 |
Clone State: Total length. More... | |
static const uint | CLONE_DESC_STATE_FLAG_START = 1 |
Clone State Flag: Start processing state. More... | |
static const uint | CLONE_DESC_STATE_FLAG_ACK = 2 |
Clone State Flag: Acknowledge processing state. More... | |
static const uint | CLONE_DATA_STATE_OFFSET = CLONE_DESC_HEADER_LEN |
Clone Data: Snapshot state in 4 bytes. More... | |
static const uint | CLONE_DATA_TASK_INDEX_OFFSET = CLONE_DATA_STATE_OFFSET + 4 |
Clone Data: Task index in 4 bytes. More... | |
static const uint | CLONE_DATA_TASK_CHUNK_OFFSET |
Clone Data: Current chunk number in 4 bytes. More... | |
static const uint | CLONE_DATA_TASK_BLOCK_OFFSET |
Clone Data: Current block number in 4 bytes. More... | |
static const uint | CLONE_DATA_FILE_IDX_OFFSET = CLONE_DATA_TASK_BLOCK_OFFSET + 4 |
Clone Data: Data file index in 4 bytes. More... | |
static const uint | CLONE_DATA_LEN_OFFSET = CLONE_DATA_FILE_IDX_OFFSET + 4 |
Clone Data: Data length in 4 bytes. More... | |
static const uint | CLONE_DATA_FOFF_OFFSET = CLONE_DATA_LEN_OFFSET + 4 |
Clone Data: Data file offset in 8 bytes. More... | |
static const uint | CLONE_DATA_FILE_SIZE_OFFSET = CLONE_DATA_FOFF_OFFSET + 8 |
Clone Data: Updated file size in 8 bytes. More... | |
static const uint | CLONE_DESC_DATA_LEN = CLONE_DATA_FILE_SIZE_OFFSET + 8 |
Clone Data: Total length. More... | |
Innodb clone descriptors.
uint choose_desc_version | ( | const byte * | ref_loc | ) |
Choose lowest descriptor version between reference locator and currently supported version.
[in] | ref_loc | reference locator |
bool clone_validate_locator | ( | const byte * | desc_loc, |
uint | desc_len | ||
) |
Check if clone locator is valid.
[in] | desc_loc | serialized descriptor |
[in] | desc_len | descriptor length |
Check a specific bit in flag.
[in] | flag | bit flag |
[in] | bit | check bit |
Set a specific bit in flag.
[in] | flag | bit flag |
[in] | bit | set bit |
|
static |
Clone Data: Data file index in 4 bytes.
|
static |
Clone Data: Updated file size in 8 bytes.
|
static |
Clone Data: Data file offset in 8 bytes.
|
static |
Clone Data: Data length in 4 bytes.
|
static |
Clone Data: Snapshot state in 4 bytes.
|
static |
Clone Data: Current block number in 4 bytes.
|
static |
Clone Data: Current chunk number in 4 bytes.
|
static |
Clone Data: Task index in 4 bytes.
|
static |
Clone Data: Total length.
|
static |
Clone File Flag: Encryption type AES.
|
static |
Clone File Flag: File is deleted.
|
static |
Clone File Flag: Compression type LZ4.
|
static |
Clone File Flag: File is renamed.
|
static |
Clone File Flag: Compression type ZLIB.
|
static |
Clone File Flag: File metadata has encryption key.
|
static |
Header: Fixed length.
|
static |
Header: Total length is stored in next 4 bytes.
|
static |
Locator: Total length.
|
static |
Maximum supported descriptor version.
The version represents the current set of descriptors and its elements.
|
static |
Clone State: Estimated number of bytes in 8 bytes.
|
static |
Clone State: Estimated number of bytes in 8 bytes.
|
static |
Clone State Flag: Acknowledge processing state.
|
static |
Clone State Flag: Start processing state.
|
static |
Clone State: flags in 2 byte [max 16 flags].
|
static |
Clone State: Total length.
|
static |
Clone State: Number of chunks in 4 bytes.
|
static |
Clone State: Number of files in 4 bytes.
|
static |
Clone State: Snapshot state in 4 bytes.
|
static |
Clone State: Task index in 4 bytes.
|
static |
Header: Descriptor type is in next 4 bytes.
|
static |
Header: Version is in first 4 bytes.
|
static |
File Metadata: Sparse file allocation size on disk in 8 bytes.
|
static |
File Metadata: Length excluding the file name.
|
static |
File Metadata: First chunk number in 4 bytes.
|
static |
File Metadata: Last chunk number in 4 bytes.
|
static |
File Metadata: File space flags in next 2 bytes [Maximum 16 flags].
|
static |
File Metadata: File name.
|
static |
File Metadata: File name length in 4 bytes.
|
static |
File Metadata: File system block size for compressed tables in 4 bytes.
|
static |
File Metadata: FSP flags in 4 bytes.
|
static |
File Metadata: File index in 4 bytes.
|
static |
File Metadata: File size in 8 bytes.
|
static |
File Metadata: Tablespace ID in 4 bytes.
|
static |
File Metadata: Snapshot state in 4 bytes.
|
static |
Locator: Clone identifier in 8 bytes.
|
static |
Locator: Clone array index in 4 bytes.
|
static |
Locator: Clone Snapshot sub-state in 1 byte.
|
static |
Locator: Snapshot identifier in 8 bytes.
|
static |
Locator: Clone Snapshot state in 1 byte.
|
static |
Task: Task block number in 4 bytes.
|
static |
Task: Task chunk number in 4 bytes.
|
static |
Task: Clone task index in 4 bytes.
|
static |
Task: Total length.