CUBRID Engine
latest
|
#include "config.h"
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#include <time.h>
#include "file_manager.h"
#include "btree.h"
#include "porting.h"
#include "porting_inline.hpp"
#include "memory_alloc.h"
#include "storage_common.h"
#include "error_manager.h"
#include "file_io.h"
#include "page_buffer.h"
#include "disk_manager.h"
#include "log_append.hpp"
#include "log_manager.h"
#include "log_impl.h"
#include "log_lsa.hpp"
#include "lock_manager.h"
#include "system_parameter.h"
#include "boot_sr.h"
#include "memory_hash.h"
#include "environment_variable.h"
#include "xserver_interface.h"
#include "oid.h"
#include "heap_file.h"
#include "bit.h"
#include "util_func.h"
#include "vacuum.h"
#include "btree_load.h"
#include "critical_section.h"
#include "fault_injection.h"
#include "thread_manager.hpp"
Go to the source code of this file.
Classes | |
struct | file_header |
struct | file_extensible_data |
struct | file_extensible_data_search_context |
struct | file_partial_sector |
struct | file_vsid_collector |
struct | file_ftab_collector |
struct | file_map_context |
struct | file_set_tde_algorithm_args |
struct | file_find_nth_context |
struct | file_tempcache_entry |
struct | file_tempcache |
struct | file_track_heap_metadata |
union | file_track_metadata |
struct | file_track_item |
struct | file_tracker_dump_heap_context |
struct | file_track_mark_heap_deleted_context |
struct | file_tracker_reuse_heap_context |
Macros | |
#define | FILE_HEADER_ALIGNED_SIZE ((INT16) (DB_ALIGN (sizeof (FILE_HEADER), MAX_ALIGNMENT))) |
#define | FILE_FLAG_NUMERABLE 0x1 /* Is file numerable */ |
#define | FILE_FLAG_TEMPORARY 0x2 /* Is file temporary */ |
#define | FILE_FLAG_ENCRYPTED_AES 0x4 /* Is file encrypted using AES */ |
#define | FILE_FLAG_ENCRYPTED_ARIA 0x8 /* Is file encrypted using ARIA */ |
#define | FILE_FLAG_ENCRYPTED_MASK 0x0000000c /* 0x4 + 0x8 */ |
#define | FILE_IS_NUMERABLE(fh) (((fh)->file_flags & FILE_FLAG_NUMERABLE) != 0) |
#define | FILE_IS_TEMPORARY(fh) (((fh)->file_flags & FILE_FLAG_TEMPORARY) != 0) |
#define | FILE_IS_TDE_ENCRYPTED(fh) (((fh)->file_flags & FILE_FLAG_ENCRYPTED_MASK) != 0) |
#define | FILE_CACHE_LAST_FIND_NTH(fh) (FILE_IS_NUMERABLE (fh) && FILE_IS_TEMPORARY (fh) && (fh)->type == FILE_TEMP) |
#define | FILE_TYPE_CAN_BE_NUMERABLE(ftype) |
#define | FILE_TYPE_IS_ALWAYS_TEMP(ftype) |
#define | FILE_TYPE_IS_SOMETIMES_TEMP(ftype) |
#define | FILE_TYPE_IS_NEVER_TEMP(ftype) (!FILE_TYPE_IS_ALWAYS_TEMP (ftype) && !FILE_TYPE_IS_SOMETIMES_TEMP (ftype)) |
#define | FILE_GET_HEADER_VPID(vfid, vpid) (vpid)->volid = (vfid)->volid; (vpid)->pageid = (vfid)->fileid |
#define | FILE_HEADER_GET_PART_FTAB(fh, parttab) |
#define | FILE_HEADER_GET_FULL_FTAB(fh, fulltab) |
#define | FILE_HEADER_GET_USER_PAGE_FTAB(fh, pagetab) |
#define | FILE_EXTDATA_HEADER_ALIGNED_SIZE (DB_ALIGN (sizeof (FILE_EXTENSIBLE_DATA), MAX_ALIGNMENT)) |
#define | FILE_FULL_PAGE_BITMAP 0xFFFFFFFFFFFFFFFF /* Full allocation bitmap */ |
#define | FILE_EMPTY_PAGE_BITMAP 0x0000000000000000 /* Empty allocation bitmap */ |
#define | FILE_ALLOC_BITMAP_NBITS ((int) (sizeof (FILE_ALLOC_BITMAP) * CHAR_BIT)) |
#define | FILE_PARTIAL_SECTOR_INITIALIZER { VSID_INITIALIZER, 0 } |
#define | FILE_TABLESPACE_DEFAULT_RATIO_EXPAND ((float) 0.01) /* 1% of current size */ |
#define | FILE_TABLESPACE_DEFAULT_MIN_EXPAND (DISK_SECTOR_NPAGES * DB_PAGESIZE); /* one sector */ |
#define | FILE_TABLESPACE_DEFAULT_MAX_EXPAND (DISK_SECTOR_NPAGES * DB_PAGESIZE * 1024); /* 1k sectors */ |
#define | FILE_TABLESPACE_FOR_PERM_NPAGES(tabspace, npages) |
#define | FILE_TABLESPACE_FOR_TEMP_NPAGES(tabspace, npages) |
#define | file_log(func, msg, ...) |
#define | FILE_PERM_TEMP_STRING(is_temp) ((is_temp) ? "temporary" : "permanent") |
#define | FILE_NUMERABLE_REGULAR_STRING(is_numerable) ((is_numerable) ? "numerable" : "regular") |
#define | FILE_TABLESPACE_MSG "\ttablespace = { init_size = %lld, expand_ratio = %f, expand_min_size = %d, expand_max_size = %d } \n" |
#define | FILE_TABLESPACE_AS_ARGS(tabspace) |
#define | FILE_HEAD_ALLOC_MSG |
#define | FILE_HEAD_ALLOC_AS_ARGS(fhead) |
#define | FILE_HEAD_FULL_MSG |
#define | FILE_HEAD_FULL_AS_ARGS(fhead) |
#define | FILE_EXTDATA_MSG(name) "\t" name ": { vpid_next = %d|%d, max_size = %d, item_size = %d, n_items = %d } \n" |
#define | FILE_EXTDATA_AS_ARGS(extdata) VPID_AS_ARGS (&(extdata)->vpid_next), (extdata)->max_size, (extdata)->size_of_item, (extdata)->n_items |
#define | FILE_PARTSECT_MSG(name) "\t" name ": { vsid = %d|%d, page bitmap = " BIT64_HEXA_PRINT_FORMAT " } \n" |
#define | FILE_PARTSECT_AS_ARGS(ps) VSID_AS_ARGS (&(ps)->vsid), (long long unsigned int) (ps)->page_bitmap |
#define | FILE_ALLOC_TYPE_STRING(alloc_type) ((alloc_type) == FILE_ALLOC_USER_PAGE ? "alloc user page" : "alloc table page") |
#define | FILE_TEMPCACHE_MSG |
#define | FILE_TEMPCACHE_AS_ARGS |
#define | FILE_TEMPCACHE_ENTRY_MSG "%p, VFID %d|%d, %s" |
#define | FILE_TEMPCACHE_ENTRY_AS_ARGS(ent) ent, VFID_AS_ARGS (&(ent)->vfid), file_type_to_string ((ent)->ftype) |
#define | FILE_TRACK_ITEM_MSG "VFID %d|%d, %s" |
#define | FILE_TRACK_ITEM_AS_ARGS(item) (item)->volid, (item)->fileid, file_type_to_string ((FILE_TYPE) (item)->type) |
#define | FILE_RV_DEALLOC_COMPENSATE true |
#define | FILE_RV_DEALLOC_RUN_POSTPONE false |
#define | FILE_FTAB_COLLECTOR_INITIALIZER { 0, 0, NULL } |
#define | FILE_USER_PAGE_MARK_DELETE_FLAG ((PAGEID) 0x80000000) |
#define | FILE_USER_PAGE_IS_MARKED_DELETED(vpid) ((((VPID *) vpid)->pageid & FILE_USER_PAGE_MARK_DELETE_FLAG) != 0) |
#define | FILE_USER_PAGE_MARK_DELETED(vpid) ((VPID *) vpid)->pageid |= FILE_USER_PAGE_MARK_DELETE_FLAG |
#define | FILE_USER_PAGE_CLEAR_MARK_DELETED(vpid) ((VPID *) vpid)->pageid &= ~FILE_USER_PAGE_MARK_DELETE_FLAG |
#define | FILE_GET_TRACKER_LOCK_MODE(file_type) (((file_type) == FILE_BTREE) ? IX_LOCK : SCH_S_LOCK) |
#define | LOG_BOOL_COUNT 3 |
#define | LOG_BOOL_COUNT 3 |
#define | UNDO_DATA_SIZE (sizeof (VFID) + sizeof (VPID)) |
#define | LOG_DATA_SIZE (sizeof (VFID) + sizeof (VPID)) |
Enumerations | |
enum | FILE_ALLOC_TYPE { FILE_ALLOC_USER_PAGE, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_TABLE_PAGE_FULL_SECTOR } |
Variables | |
static bool | file_Logging = false |
static FILE_TEMPCACHE * | file_Tempcache = NULL |
static VFID | file_Tracker_vfid = VFID_INITIALIZER |
static VPID | file_Tracker_vpid = VPID_INITIALIZER |
#define FILE_ALLOC_BITMAP_NBITS ((int) (sizeof (FILE_ALLOC_BITMAP) * CHAR_BIT)) |
Definition at line 270 of file file_manager.c.
Referenced by file_partsect_alloc(), and file_sector_map_pages().
#define FILE_ALLOC_TYPE_STRING | ( | alloc_type | ) | ((alloc_type) == FILE_ALLOC_USER_PAGE ? "alloc user page" : "alloc table page") |
Definition at line 374 of file file_manager.c.
Referenced by file_perm_alloc(), file_perm_dealloc(), file_rv_fhead_alloc(), file_rv_fhead_dealloc(), and file_temp_alloc().
#define FILE_CACHE_LAST_FIND_NTH | ( | fh | ) | (FILE_IS_NUMERABLE (fh) && FILE_IS_TEMPORARY (fh) && (fh)->type == FILE_TEMP) |
Definition at line 175 of file file_manager.c.
Referenced by file_dealloc(), and file_numerable_find_nth().
#define FILE_EMPTY_PAGE_BITMAP 0x0000000000000000 /* Empty allocation bitmap */ |
Definition at line 268 of file file_manager.c.
Referenced by file_create(), file_extdata_collect_ftab_pages(), file_partsect_is_empty(), file_perm_expand(), file_rv_perm_expand_redo(), file_table_collect_ftab_pages(), file_temp_alloc(), and file_temp_reset_user_pages().
#define FILE_EXTDATA_AS_ARGS | ( | extdata | ) | VPID_AS_ARGS (&(extdata)->vpid_next), (extdata)->max_size, (extdata)->size_of_item, (extdata)->n_items |
Definition at line 367 of file file_manager.c.
Referenced by file_extdata_find_and_remove_item(), file_extdata_merge_pages(), file_full_table_extdata_dump(), file_log_extdata_set_next(), file_numerable_add_page(), file_partial_table_extdata_dump(), file_perm_alloc(), file_perm_dealloc(), file_perm_expand(), file_rv_extdata_add(), file_rv_extdata_merge(), file_rv_extdata_remove(), file_rv_extdata_set_next(), file_rv_perm_expand_redo(), file_table_add_full_sector(), file_table_move_partial_sectors_to_header(), file_temp_alloc(), and file_user_page_table_extdata_dump().
#define FILE_EXTDATA_HEADER_ALIGNED_SIZE (DB_ALIGN (sizeof (FILE_EXTENSIBLE_DATA), MAX_ALIGNMENT)) |
Definition at line 233 of file file_manager.c.
Referenced by file_extdata_init(), file_extdata_max_size(), file_extdata_size(), and file_extdata_start().
#define FILE_EXTDATA_MSG | ( | name | ) | "\t" name ": { vpid_next = %d|%d, max_size = %d, item_size = %d, n_items = %d } \n" |
Definition at line 365 of file file_manager.c.
Referenced by file_extdata_find_and_remove_item(), file_extdata_merge_pages(), file_full_table_extdata_dump(), file_log_extdata_set_next(), file_numerable_add_page(), file_partial_table_extdata_dump(), file_perm_alloc(), file_perm_dealloc(), file_perm_expand(), file_rv_extdata_add(), file_rv_extdata_merge(), file_rv_extdata_remove(), file_rv_extdata_set_next(), file_rv_perm_expand_redo(), file_table_add_full_sector(), file_table_move_partial_sectors_to_header(), file_temp_alloc(), and file_user_page_table_extdata_dump().
#define FILE_FLAG_ENCRYPTED_AES 0x4 /* Is file encrypted using AES */ |
Definition at line 166 of file file_manager.c.
Referenced by file_get_tde_algorithm_internal(), and file_set_tde_algorithm_internal().
#define FILE_FLAG_ENCRYPTED_ARIA 0x8 /* Is file encrypted using ARIA */ |
Definition at line 167 of file file_manager.c.
Referenced by file_get_tde_algorithm_internal(), and file_set_tde_algorithm_internal().
#define FILE_FLAG_ENCRYPTED_MASK 0x0000000c /* 0x4 + 0x8 */ |
Definition at line 169 of file file_manager.c.
Referenced by file_set_tde_algorithm_internal().
#define FILE_FLAG_NUMERABLE 0x1 /* Is file numerable */ |
Definition at line 164 of file file_manager.c.
Referenced by file_create().
#define FILE_FLAG_TEMPORARY 0x2 /* Is file temporary */ |
Definition at line 165 of file file_manager.c.
Referenced by file_create().
#define FILE_FTAB_COLLECTOR_INITIALIZER { 0, 0, NULL } |
Definition at line 416 of file file_manager.c.
Referenced by file_temp_reset_user_pages().
#define FILE_FULL_PAGE_BITMAP 0xFFFFFFFFFFFFFFFF /* Full allocation bitmap */ |
Definition at line 267 of file file_manager.c.
Referenced by file_partsect_is_full(), file_perm_dealloc(), and file_temp_reset_user_pages().
#define FILE_GET_HEADER_VPID | ( | vfid, | |
vpid | |||
) | (vpid)->volid = (vfid)->volid; (vpid)->pageid = (vfid)->fileid |
Definition at line 189 of file file_manager.c.
Referenced by file_alloc(), file_alloc_multiple(), file_alloc_sticky_first_page(), file_apply_tde_algorithm(), file_check_vpid(), file_descriptor_dump(), file_descriptor_get(), file_descriptor_update(), file_destroy(), file_dump(), file_get_num_user_pages(), file_get_sticky_first_page(), file_get_tde_algorithm(), file_get_type(), file_header_copy(), file_is_temp(), file_map_pages(), file_numerable_add_page(), file_numerable_find_nth(), file_numerable_truncate(), file_rv_dealloc_internal(), file_set_tde_algorithm(), file_table_check(), file_temp_alloc(), file_temp_reset_user_pages(), file_temp_set_type(), file_tracker_item_reuse_heap(), and file_tracker_spacedb().
#define FILE_GET_TRACKER_LOCK_MODE | ( | file_type | ) | (((file_type) == FILE_BTREE) ? IX_LOCK : SCH_S_LOCK) |
Definition at line 562 of file file_manager.c.
Referenced by file_tracker_get_and_protect(), and file_tracker_interruptable_iterate().
#define FILE_HEAD_ALLOC_AS_ARGS | ( | fhead | ) |
Definition at line 338 of file file_manager.c.
Referenced by file_alloc(), file_perm_alloc(), file_perm_dealloc(), file_perm_expand(), file_rv_fhead_alloc(), file_rv_fhead_dealloc(), file_rv_perm_expand_redo(), file_rv_perm_expand_undo(), and file_temp_alloc().
#define FILE_HEAD_ALLOC_MSG |
Definition at line 330 of file file_manager.c.
Referenced by file_alloc(), file_perm_alloc(), file_perm_dealloc(), file_perm_expand(), file_rv_fhead_alloc(), file_rv_fhead_dealloc(), file_rv_perm_expand_redo(), file_rv_perm_expand_undo(), and file_temp_alloc().
#define FILE_HEAD_FULL_AS_ARGS | ( | fhead | ) |
Definition at line 355 of file file_manager.c.
Referenced by file_create(), file_destroy(), file_header_dump(), file_numerable_add_page(), file_temp_alloc(), and file_temp_reset_user_pages().
#define FILE_HEAD_FULL_MSG |
Definition at line 346 of file file_manager.c.
Referenced by file_create(), file_destroy(), file_header_dump(), file_numerable_add_page(), file_temp_alloc(), and file_temp_reset_user_pages().
#define FILE_HEADER_ALIGNED_SIZE ((INT16) (DB_ALIGN (sizeof (FILE_HEADER), MAX_ALIGNMENT))) |
Definition at line 161 of file file_manager.c.
Referenced by file_create().
#define FILE_HEADER_GET_FULL_FTAB | ( | fh, | |
fulltab | |||
) |
Definition at line 196 of file file_manager.c.
Referenced by file_apply_tde_algorithm(), file_check_vpid(), file_create(), file_destroy(), file_header_sanity_check(), file_map_pages(), file_perm_dealloc(), file_table_add_full_sector(), file_table_append_full_sector_page(), file_table_collect_all_vsids(), file_table_collect_ftab_pages(), and file_table_dump().
#define FILE_HEADER_GET_PART_FTAB | ( | fh, | |
parttab | |||
) |
Definition at line 192 of file file_manager.c.
Referenced by file_apply_tde_algorithm(), file_check_vpid(), file_create(), file_destroy(), file_header_sanity_check(), file_map_pages(), file_perm_alloc(), file_perm_dealloc(), file_perm_expand(), file_rv_perm_expand_redo(), file_rv_perm_expand_undo(), file_table_collect_all_vsids(), file_table_collect_ftab_pages(), file_table_dump(), file_table_move_partial_sectors_to_header(), file_temp_alloc(), and file_temp_reset_user_pages().
#define FILE_HEADER_GET_USER_PAGE_FTAB | ( | fh, | |
pagetab | |||
) |
Definition at line 201 of file file_manager.c.
Referenced by file_check_vpid(), file_create(), file_dealloc(), file_numerable_add_page(), file_numerable_find_nth(), file_rv_dealloc_internal(), file_rv_user_page_unmark_delete_logical(), file_table_check(), file_table_collect_ftab_pages(), file_table_dump(), and file_temp_reset_user_pages().
#define FILE_IS_NUMERABLE | ( | fh | ) | (((fh)->file_flags & FILE_FLAG_NUMERABLE) != 0) |
Definition at line 171 of file file_manager.c.
Referenced by file_alloc(), file_alloc_multiple(), file_check_vpid(), file_dealloc(), file_numerable_add_page(), file_numerable_find_nth(), file_numerable_truncate(), file_rv_dealloc_internal(), file_rv_user_page_unmark_delete_logical(), file_table_check(), file_table_collect_ftab_pages(), file_table_dump(), file_temp_reset_user_pages(), and file_tempcache_put().
#define FILE_IS_TDE_ENCRYPTED | ( | fh | ) | (((fh)->file_flags & FILE_FLAG_ENCRYPTED_MASK) != 0) |
Definition at line 173 of file file_manager.c.
#define FILE_IS_TEMPORARY | ( | fh | ) | (((fh)->file_flags & FILE_FLAG_TEMPORARY) != 0) |
Definition at line 172 of file file_manager.c.
Referenced by file_alloc(), file_alloc_multiple(), file_apply_tde_algorithm(), file_dealloc(), file_destroy(), file_header_sanity_check(), file_header_update_mark_deleted(), file_is_temp(), file_map_pages(), file_numerable_add_page(), file_perm_dealloc(), file_perm_expand(), file_postpone_destroy(), file_rv_dealloc_internal(), file_rv_perm_expand_redo(), file_rv_perm_expand_undo(), file_rv_user_page_unmark_delete_logical(), file_set_tde_algorithm(), file_table_add_full_sector(), file_table_collect_all_vsids(), file_table_collect_ftab_pages(), file_table_dump(), file_table_move_partial_sectors_to_header(), file_temp_alloc(), file_temp_reset_user_pages(), and file_temp_set_type().
#define file_log | ( | func, | |
msg, | |||
... | |||
) |
Definition at line 316 of file file_manager.c.
Referenced by file_alloc(), file_alloc_sticky_first_page(), file_create(), file_dealloc(), file_destroy(), file_extdata_collect_ftab_pages(), file_extdata_find_and_remove_item(), file_extdata_merge_pages(), file_header_update_mark_deleted(), file_log_extdata_set_next(), file_numerable_add_page(), file_numerable_find_nth(), file_perm_alloc(), file_perm_dealloc(), file_perm_expand(), file_rv_dealloc_on_postpone(), file_rv_dealloc_on_undo(), file_rv_extdata_add(), file_rv_extdata_merge(), file_rv_extdata_remove(), file_rv_extdata_set_next(), file_rv_fhead_alloc(), file_rv_fhead_dealloc(), file_rv_fhead_set_last_user_page_ftab(), file_rv_fhead_sticky_page(), file_rv_header_update_mark_deleted(), file_rv_partsect_update(), file_rv_perm_expand_redo(), file_rv_perm_expand_undo(), file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_rv_tracker_reuse_heap(), file_rv_user_page_mark_delete(), file_rv_user_page_unmark_delete_logical(), file_rv_user_page_unmark_delete_physical(), file_table_add_full_sector(), file_table_append_full_sector_page(), file_table_collect_ftab_pages(), file_table_move_partial_sectors_to_header(), file_temp_alloc(), file_temp_reset_user_pages(), file_tempcache_cache_or_drop_entries(), file_tempcache_drop_tran_temp_files(), file_tempcache_get(), file_tempcache_pop_tran_file(), file_tempcache_push_tran_file(), file_tempcache_put(), file_tracker_item_mark_heap_deleted(), file_tracker_item_reuse_heap(), file_tracker_register_internal(), and file_tracker_unregister().
#define FILE_NUMERABLE_REGULAR_STRING | ( | is_numerable | ) | ((is_numerable) ? "numerable" : "regular") |
Definition at line 322 of file file_manager.c.
Referenced by file_create().
#define FILE_PARTIAL_SECTOR_INITIALIZER { VSID_INITIALIZER, 0 } |
Definition at line 281 of file file_manager.c.
Referenced by file_sector_map_dealloc(), file_sector_map_pages(), and file_temp_alloc().
#define FILE_PARTSECT_AS_ARGS | ( | ps | ) | VSID_AS_ARGS (&(ps)->vsid), (long long unsigned int) (ps)->page_bitmap |
Definition at line 372 of file file_manager.c.
Referenced by file_extdata_collect_ftab_pages(), file_partial_table_item_dump(), file_perm_alloc(), file_perm_dealloc(), file_rv_partsect_update(), file_table_collect_ftab_pages(), and file_temp_alloc().
#define FILE_PARTSECT_MSG | ( | name | ) | "\t" name ": { vsid = %d|%d, page bitmap = " BIT64_HEXA_PRINT_FORMAT " } \n" |
Definition at line 370 of file file_manager.c.
Referenced by file_extdata_collect_ftab_pages(), file_partial_table_item_dump(), file_perm_alloc(), file_perm_dealloc(), file_rv_partsect_update(), file_table_collect_ftab_pages(), and file_temp_alloc().
#define FILE_PERM_TEMP_STRING | ( | is_temp | ) | ((is_temp) ? "temporary" : "permanent") |
Definition at line 321 of file file_manager.c.
Referenced by file_alloc(), and file_create().
#define FILE_RV_DEALLOC_COMPENSATE true |
Definition at line 406 of file file_manager.c.
Referenced by file_rv_dealloc_internal(), and file_rv_dealloc_on_undo().
#define FILE_RV_DEALLOC_RUN_POSTPONE false |
Definition at line 407 of file file_manager.c.
Referenced by file_rv_dealloc_on_postpone().
#define FILE_TABLESPACE_AS_ARGS | ( | tabspace | ) |
Definition at line 326 of file file_manager.c.
Referenced by file_create(), and file_perm_expand().
#define FILE_TABLESPACE_DEFAULT_MAX_EXPAND (DISK_SECTOR_NPAGES * DB_PAGESIZE * 1024); /* 1k sectors */ |
Definition at line 290 of file file_manager.c.
#define FILE_TABLESPACE_DEFAULT_MIN_EXPAND (DISK_SECTOR_NPAGES * DB_PAGESIZE); /* one sector */ |
Definition at line 289 of file file_manager.c.
#define FILE_TABLESPACE_DEFAULT_RATIO_EXPAND ((float) 0.01) /* 1% of current size */ |
Definition at line 288 of file file_manager.c.
#define FILE_TABLESPACE_FOR_PERM_NPAGES | ( | tabspace, | |
npages | |||
) |
Definition at line 292 of file file_manager.c.
Referenced by file_create_with_npages().
#define FILE_TABLESPACE_FOR_TEMP_NPAGES | ( | tabspace, | |
npages | |||
) |
Definition at line 298 of file file_manager.c.
Referenced by file_create_ehash(), file_create_ehash_dir(), and file_create_temp_internal().
#define FILE_TABLESPACE_MSG "\ttablespace = { init_size = %lld, expand_ratio = %f, expand_min_size = %d, expand_max_size = %d } \n" |
Definition at line 324 of file file_manager.c.
Referenced by file_create(), and file_perm_expand().
#define FILE_TEMPCACHE_AS_ARGS |
Definition at line 381 of file file_manager.c.
Referenced by file_tempcache_get(), and file_tempcache_put().
#define FILE_TEMPCACHE_ENTRY_AS_ARGS | ( | ent | ) | ent, VFID_AS_ARGS (&(ent)->vfid), file_type_to_string ((ent)->ftype) |
Definition at line 387 of file file_manager.c.
Referenced by file_tempcache_cache_or_drop_entries(), file_tempcache_get(), file_tempcache_pop_tran_file(), file_tempcache_push_tran_file(), and file_tempcache_put().
#define FILE_TEMPCACHE_ENTRY_MSG "%p, VFID %d|%d, %s" |
Definition at line 386 of file file_manager.c.
Referenced by file_tempcache_cache_or_drop_entries(), file_tempcache_get(), file_tempcache_pop_tran_file(), file_tempcache_push_tran_file(), and file_tempcache_put().
#define FILE_TEMPCACHE_MSG |
Definition at line 377 of file file_manager.c.
Referenced by file_tempcache_get(), and file_tempcache_put().
#define FILE_TRACK_ITEM_AS_ARGS | ( | item | ) | (item)->volid, (item)->fileid, file_type_to_string ((FILE_TYPE) (item)->type) |
Definition at line 390 of file file_manager.c.
Referenced by file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_rv_tracker_reuse_heap(), and file_tracker_register_internal().
#define FILE_TRACK_ITEM_MSG "VFID %d|%d, %s" |
Definition at line 389 of file file_manager.c.
Referenced by file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_rv_tracker_reuse_heap(), and file_tracker_register_internal().
#define FILE_TYPE_CAN_BE_NUMERABLE | ( | ftype | ) |
Definition at line 179 of file file_manager.c.
Referenced by file_dealloc().
#define FILE_TYPE_IS_ALWAYS_TEMP | ( | ftype | ) |
Definition at line 182 of file file_manager.c.
#define FILE_TYPE_IS_NEVER_TEMP | ( | ftype | ) | (!FILE_TYPE_IS_ALWAYS_TEMP (ftype) && !FILE_TYPE_IS_SOMETIMES_TEMP (ftype)) |
Definition at line 186 of file file_manager.c.
#define FILE_TYPE_IS_SOMETIMES_TEMP | ( | ftype | ) |
Definition at line 184 of file file_manager.c.
#define FILE_USER_PAGE_CLEAR_MARK_DELETED | ( | vpid | ) | ((VPID *) vpid)->pageid &= ~FILE_USER_PAGE_MARK_DELETE_FLAG |
Definition at line 448 of file file_manager.c.
Referenced by file_compare_vpids(), file_rv_user_page_unmark_delete_logical(), file_rv_user_page_unmark_delete_physical(), and file_table_check_page_is_in_sectors().
#define FILE_USER_PAGE_IS_MARKED_DELETED | ( | vpid | ) | ((((VPID *) vpid)->pageid & FILE_USER_PAGE_MARK_DELETE_FLAG) != 0) |
Definition at line 446 of file file_manager.c.
Referenced by file_check_vpid(), file_dealloc(), file_extdata_find_nth_vpid(), file_extdata_find_nth_vpid_and_skip_marked(), file_rv_dealloc_internal(), file_rv_user_page_mark_delete(), file_rv_user_page_unmark_delete_logical(), file_rv_user_page_unmark_delete_physical(), and file_user_page_table_item_dump().
#define FILE_USER_PAGE_MARK_DELETE_FLAG ((PAGEID) 0x80000000) |
Definition at line 445 of file file_manager.c.
#define FILE_USER_PAGE_MARK_DELETED | ( | vpid | ) | ((VPID *) vpid)->pageid |= FILE_USER_PAGE_MARK_DELETE_FLAG |
Definition at line 447 of file file_manager.c.
Referenced by file_dealloc(), and file_rv_user_page_mark_delete().
#define LOG_BOOL_COUNT 3 |
#define LOG_BOOL_COUNT 3 |
Referenced by file_dealloc().
Referenced by file_alloc().
typedef UINT64 FILE_ALLOC_BITMAP |
Definition at line 266 of file file_manager.c.
typedef int(* FILE_EXTDATA_FUNC) (THREAD_ENTRY *thread_p, const FILE_EXTENSIBLE_DATA *extdata, bool *stop, void *args) |
Definition at line 247 of file file_manager.c.
typedef int(* FILE_EXTDATA_ITEM_FUNC) (THREAD_ENTRY *thread_p, const void *data, int index, bool *stop, void *args) |
Definition at line 249 of file file_manager.c.
typedef struct file_extensible_data FILE_EXTENSIBLE_DATA |
Definition at line 224 of file file_manager.c.
Definition at line 237 of file file_manager.c.
typedef struct file_find_nth_context FILE_FIND_NTH_CONTEXT |
Definition at line 452 of file file_manager.c.
typedef struct file_ftab_collector FILE_FTAB_COLLECTOR |
Definition at line 409 of file file_manager.c.
typedef struct file_header FILE_HEADER |
Definition at line 83 of file file_manager.c.
typedef struct file_map_context FILE_MAP_CONTEXT |
Definition at line 419 of file file_manager.c.
typedef struct file_partial_sector FILE_PARTIAL_SECTOR |
Definition at line 274 of file file_manager.c.
typedef struct file_set_tde_algorithm_args FILE_SET_TDE_ALGORITHM_ARGS |
Definition at line 434 of file file_manager.c.
typedef struct file_tempcache FILE_TEMPCACHE |
Definition at line 476 of file file_manager.c.
typedef struct file_tempcache_entry FILE_TEMPCACHE_ENTRY |
Definition at line 467 of file file_manager.c.
typedef struct file_track_heap_metadata FILE_TRACK_HEAP_METADATA |
Definition at line 509 of file file_manager.c.
typedef struct file_track_item FILE_TRACK_ITEM |
Definition at line 524 of file file_manager.c.
typedef int(* FILE_TRACK_ITEM_FUNC) (THREAD_ENTRY *thread_p, PAGE_PTR page_of_item, FILE_EXTENSIBLE_DATA *extdata, int index_item, bool *stop, void *args) |
Definition at line 556 of file file_manager.c.
Definition at line 542 of file file_manager.c.
typedef union file_track_metadata FILE_TRACK_METADATA |
Definition at line 516 of file file_manager.c.
typedef struct file_tracker_dump_heap_context FILE_TRACKER_DUMP_HEAP_CONTEXT |
Definition at line 535 of file file_manager.c.
typedef struct file_tracker_reuse_heap_context FILE_TRACKER_REUSE_HEAP_CONTEXT |
Definition at line 549 of file file_manager.c.
typedef struct file_vsid_collector FILE_VSID_COLLECTOR |
Definition at line 306 of file file_manager.c.
enum FILE_ALLOC_TYPE |
Enumerator | |
---|---|
FILE_ALLOC_USER_PAGE | |
FILE_ALLOC_TABLE_PAGE | |
FILE_ALLOC_TABLE_PAGE_FULL_SECTOR |
Definition at line 399 of file file_manager.c.
int file_alloc | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE_INIT_PAGE_FUNC | f_init, | ||
void * | f_init_args, | ||
VPID * | vpid_out, | ||
PAGE_PTR * | page_out | ||
) |
Definition at line 5256 of file file_manager.c.
References ARG_FILE_LINE, assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, er_log_debug, FILE_ALLOC_USER_PAGE, FILE_GET_HEADER_VPID, file_get_tde_algorithm_internal(), FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, file_header_sanity_check(), FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_log, file_numerable_add_page(), file_perm_alloc(), FILE_PERM_TEMP_STRING, file_temp_alloc(), log_sysop_abort(), log_sysop_end_logical_undo(), log_sysop_start_atomic(), MAX_ALIGNMENT, NEW_PAGE, NO_ERROR, NULL, OLD_PAGE, PAGE_UNKNOWN, pgbuf_fix, pgbuf_get_page_ptype(), pgbuf_get_tde_algorithm(), PGBUF_LATCH_WRITE, pgbuf_set_tde_algorithm(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, PTR_ALIGN, RVFL_ALLOC, file_header::self, TDE_ALGORITHM_NONE, tde_get_algorithm_name(), UNDO_DATA_SIZE, VFID_AS_ARGS, VFID_COPY, VFID_ISNULL, VPID_AS_ARGS, VPID_COPY, VPID_ISNULL, and VPID_SET_NULL.
Referenced by btree_get_new_page(), btree_load_new_page(), catalog_get_new_page(), ehash_create_helper(), ehash_insert_to_bucket_after_create(), ehash_split_bucket(), file_alloc_multiple(), file_alloc_sticky_first_page(), file_numerable_find_nth(), file_tracker_register_internal(), heap_alloc_new_page(), heap_vpid_alloc(), overflow_update(), qmgr_get_external_file_page(), sort_add_new_file(), vacuum_add_dropped_file(), vacuum_consume_buffer_log_blocks(), and vacuum_create_file_for_vacuum_data().
int file_alloc_multiple | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE_INIT_PAGE_FUNC | f_init, | ||
void * | f_init_args, | ||
int | npages, | ||
VPID * | vpids_out | ||
) |
Definition at line 5442 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, file_alloc(), FILE_GET_HEADER_VPID, file_header_sanity_check(), FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, log_check_system_op_is_started(), log_sysop_abort(), log_sysop_attach_to_outer(), log_sysop_start(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, VFID_ISNULL, and VPID_INITIALIZER.
Referenced by ehash_expand_directory(), overflow_insert(), and sort_checkalloc_numpages_of_outfiles().
int file_alloc_sticky_first_page | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE_INIT_PAGE_FUNC | f_init, | ||
void * | f_init_args, | ||
VPID * | vpid_out, | ||
PAGE_PTR * | page_out | ||
) |
Definition at line 5532 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, DONT_FREE, file_alloc(), FILE_GET_HEADER_VPID, file_header_sanity_check(), file_log, log_append_undoredo_data2(), file_header::n_page_user, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, pgbuf_get_lsa(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, RVFL_FHEAD_STICKY_PAGE, VFID_AS_ARGS, VFID_ISNULL, VPID_AS_ARGS, VPID_ISNULL, VPID_SET_NULL, and file_header::vpid_sticky_first.
Referenced by btree_create_file(), catalog_create(), file_tracker_create(), heap_create_internal(), and vacuum_create_file_for_dropped_files().
int file_apply_tde_algorithm | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
const TDE_ALGORITHM | tde_algo | ||
) |
Definition at line 5856 of file file_manager.c.
References ARG_FILE_LINE, file_map_context::args, assert, ASSERT_ERROR_AND_SET, db_private_free, er_log_debug, file_extdata_apply_funcs(), file_file_map_set_tde_algorithm(), FILE_GET_HEADER_VPID, file_get_tde_algorithm_internal(), FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, file_header_sanity_check(), FILE_IS_TEMPORARY, file_sector_map_pages(), file_set_tde_algorithm(), file_table_collect_ftab_pages(), file_map_context::ftab_collector, file_map_context::func, file_map_context::is_partial, file_map_context::latch_cond, file_map_context::latch_mode, file_header::n_page_user, NO_ERROR, NULL, OLD_PAGE, file_ftab_collector::partsect_ftab, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_header::self, file_set_tde_algorithm_args::skip_logging, file_map_context::stop, file_set_tde_algorithm_args::tde_algo, TDE_ALGORITHM_NONE, tde_get_algorithm_name(), VFID_AS_ARGS, and VFID_ISNULL.
Referenced by btree_create_file(), btree_create_overflow_key_file(), heap_create_internal(), heap_ovf_find_vfid(), qmgr_create_result_file(), qmgr_get_new_page(), sort_add_new_file(), sort_inphase_sort(), and xfile_apply_tde_to_class_files().
DISK_ISVALID file_check_vpid | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
const VPID * | vpid_lookup | ||
) |
Definition at line 6679 of file file_manager.c.
References assert, ASSERT_ERROR, assert_release, disk_compare_vsids(), DISK_ERROR, DISK_INVALID, DISK_VALID, file_compare_vpids(), file_extdata_at(), file_extdata_search_item(), FILE_GET_HEADER_VPID, FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_HEADER_GET_USER_PAGE_FTAB, file_header_sanity_check(), FILE_IS_NUMERABLE, file_partsect_is_bit_set(), file_partsect_pageid_to_offset(), FILE_USER_PAGE_IS_MARKED_DELETED, NO_ERROR, NULL, OLD_PAGE, vpid::pageid, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, and VSID_FROM_VPID.
Referenced by btree_check_pages(), catalog_check_class_consistency(), heap_check_all_pages(), and heap_check_all_pages_by_heapchain().
Definition at line 3003 of file file_manager.c.
References file_track_item::fileid, and file_track_item::volid.
Referenced by file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_tracker_apply_to_file(), file_tracker_interruptable_iterate(), file_tracker_register_internal(), and file_tracker_unregister().
Definition at line 2979 of file file_manager.c.
References vfid::fileid, and vfid::volid.
Definition at line 2952 of file file_manager.c.
References FILE_USER_PAGE_CLEAR_MARK_DELETED, vpid::pageid, and vpid::volid.
Referenced by file_check_vpid(), file_dealloc(), file_rv_dealloc_internal(), and file_rv_user_page_unmark_delete_logical().
int file_create | ( | THREAD_ENTRY * | thread_p, |
FILE_TYPE | file_type, | ||
FILE_TABLESPACE * | tablespace, | ||
FILE_DESCRIPTORS * | des, | ||
bool | is_temp, | ||
bool | is_numerable, | ||
VFID * | vfid | ||
) |
Definition at line 3295 of file file_manager.c.
References ARG_FILE_LINE, assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, CEIL_PTVDIV, DB_ALIGN, DB_PAGESIZE, DB_PERMANENT_DATA_PURPOSE, db_private_alloc, db_private_free, DB_SECTORSIZE, DB_TEMPORARY_DATA_PURPOSE, file_header::descriptor, disk_compare_vsids(), disk_reserve_sectors(), DISK_SECTOR_NPAGES, DISK_UNKNOWN_PURPOSE, disk_unreserve_ordered_sectors(), ER_ERROR_SEVERITY, ER_FAILED, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), FILE_BTREE, FILE_EMPTY_PAGE_BITMAP, file_extdata_append(), file_extdata_at(), file_extdata_end(), file_extdata_init(), file_extdata_is_empty(), file_extdata_is_full(), file_extdata_item_count(), file_extdata_max_size(), file_extdata_remove_at(), file_extdata_size(), file_extdata_start(), FILE_FLAG_NUMERABLE, FILE_FLAG_TEMPORARY, file_header::file_flags, FILE_HEAD_FULL_AS_ARGS, FILE_HEAD_FULL_MSG, FILE_HEADER_ALIGNED_SIZE, FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_HEADER_GET_USER_PAGE_FTAB, file_header_sanity_check(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, file_log, FILE_NUMERABLE_REGULAR_STRING, file_partsect_is_bit_set(), file_partsect_is_full(), file_partsect_pageid_to_offset(), file_partsect_set_bit(), FILE_PERM_TEMP_STRING, FILE_TABLESPACE_AS_ARGS, FILE_TABLESPACE_MSG, FILE_TEMP, FILE_TRACKER, file_tracker_register(), file_type_to_string(), vfid::fileid, file_header::first_index_find_nth_last, FREE, i, file_tablespace::initial_size, log_sysop_abort(), log_sysop_end_logical_undo(), log_sysop_start(), logtb_get_current_mvccid(), logtb_set_check_interrupt(), MAX_ALIGNMENT, file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_mark_delete, file_header::n_page_total, file_header::n_page_user, file_header::n_sector_empty, file_header::n_sector_full, file_header::n_sector_partial, file_header::n_sector_total, NEW_PAGE, spacedb_files::nfile, NO_ERROR, spacedb_files::npage_ftab, spacedb_files::npage_reserved, spacedb_files::npage_user, NULL, NULL_OFFSET, NULL_VOLID, file_header::offset_to_full_ftab, file_header::offset_to_last_temp_alloc, file_header::offset_to_partial_ftab, file_header::offset_to_user_page_ftab, file_partial_sector::page_bitmap, PAGE_FTAB, vpid::pageid, pgbuf_fix, PGBUF_LATCH_WRITE, pgbuf_log_new_page(), pgbuf_set_dirty(), pgbuf_set_dirty_and_free, pgbuf_set_page_ptype(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, file_header::reserved0, file_header::reserved1, file_header::reserved2, file_header::reserved3, RVFL_DESTROY, vsid::sectid, SECTOR_FIRST_PAGEID, SECTOR_FROM_PAGEID, SECTOR_LAST_PAGEID, file_header::self, file_tempcache::spacedb_temp, file_header::tablespace, file_header::time_creation, file_header::type, vacuum_is_file_dropped(), VFID_AS_ARGS, VFID_INITIALIZER, VFID_ISNULL, VFID_SET_NULL, vpid::volid, vfid::volid, vsid::volid, file_header::volid_last_expand, VPID_COPY, VPID_EQ, file_header::vpid_find_nth_last, VPID_INITIALIZER, file_header::vpid_last_temp_alloc, file_header::vpid_last_user_page_ftab, file_extensible_data::vpid_next, VPID_SET_NULL, file_header::vpid_sticky_first, file_partial_sector::vsid, and VSID_IS_SECTOR_OF_VPID.
Referenced by file_create_ehash(), file_create_ehash_dir(), file_create_temp_internal(), and file_create_with_npages().
int file_create_ehash | ( | THREAD_ENTRY * | thread_p, |
int | npages, | ||
bool | is_tmp, | ||
FILE_EHASH_DES * | des_ehash, | ||
VFID * | vfid | ||
) |
Definition at line 3245 of file file_manager.c.
References assert, file_create(), FILE_EXTENDIBLE_HASH, FILE_TABLESPACE_FOR_TEMP_NPAGES, and file_header::tablespace.
Referenced by ehash_create_helper().
int file_create_ehash_dir | ( | THREAD_ENTRY * | thread_p, |
int | npages, | ||
bool | is_tmp, | ||
FILE_EHASH_DES * | des_ehash, | ||
VFID * | vfid | ||
) |
Definition at line 3269 of file file_manager.c.
References assert, file_create(), FILE_EXTENDIBLE_HASH_DIRECTORY, FILE_TABLESPACE_FOR_TEMP_NPAGES, and file_header::tablespace.
Referenced by ehash_create_helper().
int file_create_heap | ( | THREAD_ENTRY * | thread_p, |
bool | reuse_oid, | ||
const OID * | class_oid, | ||
VFID * | vfid | ||
) |
Definition at line 3122 of file file_manager.c.
References assert, file_heap_des::class_oid, file_create_with_npages(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, file_descriptors::heap, NULL, and STATIC_INLINE.
Referenced by heap_create_internal().
int file_create_query_area | ( | THREAD_ENTRY * | thread_p, |
VFID * | vfid | ||
) |
Definition at line 3228 of file file_manager.c.
References file_create_temp_internal(), and FILE_QUERY_AREA.
Referenced by qmgr_create_result_file().
int file_create_temp | ( | THREAD_ENTRY * | thread_p, |
int | npages, | ||
VFID * | vfid | ||
) |
Definition at line 3201 of file file_manager.c.
References file_create_temp_internal(), and FILE_TEMP.
Referenced by qmgr_get_new_page(), and sort_inphase_sort().
STATIC_INLINE int file_create_temp_internal | ( | THREAD_ENTRY * | thread_p, |
int | npages, | ||
FILE_TYPE | ftype, | ||
bool | is_numerable, | ||
VFID * | vfid_out | ||
) |
Definition at line 3151 of file file_manager.c.
References assert, ASSERT_ERROR, file_create(), FILE_TABLESPACE_FOR_TEMP_NPAGES, file_tempcache_get(), file_tempcache_push_tran_file(), file_tempcache_retire_entry(), file_tempcache_entry::ftype, NO_ERROR, NULL, file_header::tablespace, file_tempcache_entry::vfid, and VFID_ISNULL.
Referenced by file_create_query_area(), file_create_temp(), and file_create_temp_numerable().
int file_create_temp_numerable | ( | THREAD_ENTRY * | thread_p, |
int | npages, | ||
VFID * | vfid | ||
) |
Definition at line 3215 of file file_manager.c.
References file_create_temp_internal(), and FILE_TEMP.
Referenced by sort_add_new_file().
int file_create_with_npages | ( | THREAD_ENTRY * | thread_p, |
FILE_TYPE | file_type, | ||
int | npages, | ||
FILE_DESCRIPTORS * | des, | ||
VFID * | vfid | ||
) |
Definition at line 3097 of file file_manager.c.
References assert, file_create(), FILE_TABLESPACE_FOR_PERM_NPAGES, FILE_TEMP, and file_header::tablespace.
Referenced by btree_create_file(), btree_create_overflow_key_file(), catalog_create(), file_create_heap(), file_tracker_create(), heap_ovf_find_vfid(), vacuum_create_file_for_dropped_files(), and vacuum_create_file_for_vacuum_data().
int file_dealloc | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
const VPID * | vpid, | ||
FILE_TYPE | file_type_hint | ||
) |
Definition at line 5972 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, DONT_FREE, ER_FAILED, FILE_CACHE_LAST_FIND_NTH, file_compare_vpids(), file_extdata_at(), file_extdata_search_item(), FILE_EXTENDIBLE_HASH, FILE_EXTENDIBLE_HASH_DIRECTORY, FILE_HEADER_GET_USER_PAGE_FTAB, file_header_update_mark_deleted(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_log, FILE_TEMP, FILE_TYPE_CAN_BE_NUMERABLE, file_type_to_string(), FILE_UNKNOWN_TYPE, FILE_USER_PAGE_IS_MARKED_DELETED, FILE_USER_PAGE_MARK_DELETED, vfid::fileid, file_header::first_index_find_nth_last, log_append_postpone(), log_append_undoredo_data(), LOG_DATA_ADDR_INITIALIZER, LOG_DATA_SIZE, MAX_ALIGNMENT, NO_ERROR, NULL, log_data_addr::offset, OLD_PAGE, vpid::pageid, pgbuf_fix, pgbuf_get_lsa(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, log_data_addr::pgptr, PTR_ALIGN, RVFL_DEALLOC, RVFL_USER_PAGE_MARK_DELETE, file_header::self, file_header::type, VFID_AS_ARGS, VFID_COPY, vpid::volid, vfid::volid, VPID_AS_ARGS, VPID_COPY, VPID_EQ, file_header::vpid_find_nth_last, VPID_SET_NULL, and file_header::vpid_sticky_first.
Referenced by btree_merge_node_and_advance(), btree_overflow_remove_object(), catalog_drop_representation_helper(), catalog_reclaim_space(), catalog_rv_ovf_page_logical_insert_undo(), ehash_merge(), ehash_split_bucket(), file_numerable_truncate(), file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_tracker_unregister(), heap_remove_page_on_vacuum(), heap_vpid_remove(), overflow_delete_internal(), overflow_update(), and vacuum_data_empty_page().
int file_descriptor_dump | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE * | fp | ||
) |
Definition at line 11471 of file file_manager.c.
References ASSERT_ERROR_AND_SET, FILE_GET_HEADER_VPID, file_header_dump_descriptor(), file_header_sanity_check(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, and pgbuf_unfix.
Referenced by heap_dump().
int file_descriptor_get | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE_DESCRIPTORS * | desc_out | ||
) |
Definition at line 11403 of file file_manager.c.
References ASSERT_ERROR_AND_SET, file_header::descriptor, FILE_GET_HEADER_VPID, file_header_sanity_check(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, and pgbuf_unfix.
Referenced by btree_check_by_btid(), btree_dump_capacity(), btree_fix_ovfl_oid_pages_by_btid(), heap_capacity_next_scan(), heap_check_heap_file(), heap_dump(), heap_dump_capacity(), vacuum_data_load_and_recover(), vacuum_heap_get_hfid_and_file_type(), and vacuum_reset_data_after_copydb().
int file_descriptor_update | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
void * | des_new | ||
) |
Definition at line 11435 of file file_manager.c.
References ASSERT_ERROR_AND_SET, file_header::descriptor, FILE_GET_HEADER_VPID, file_header_sanity_check(), FREE, log_append_undoredo_data2(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, and RVFL_FILEDESC_UPD.
Referenced by heap_create_internal(), vacuum_create_file_for_vacuum_data(), and vacuum_data_empty_page().
int file_destroy | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
bool | is_temp | ||
) |
Definition at line 4041 of file file_manager.c.
References ARG_FILE_LINE, assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, DB_PERMANENT_DATA_PURPOSE, db_private_alloc, db_private_free, DB_TEMPORARY_DATA_PURPOSE, DISK_SECTOR_NPAGES, disk_unreserve_ordered_sectors(), ER_ERROR_SEVERITY, ER_FAILED, er_log_debug, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), file_extdata_apply_funcs(), file_extdata_collect_ftab_pages(), FILE_GET_HEADER_VPID, file_get_tde_algorithm_internal(), FILE_HEAD_FULL_AS_ARGS, FILE_HEAD_FULL_MSG, FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_log, file_partsect_is_bit_set(), file_sector_map_dealloc(), file_table_collect_all_vsids(), file_tracker_unregister(), log_check_system_op_is_started(), logtb_set_check_interrupt(), file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_user, file_header::n_sector_total, file_vsid_collector::n_vsids, spacedb_files::nfile, NO_ERROR, spacedb_files::npage_ftab, spacedb_files::npage_reserved, spacedb_files::npage_user, file_ftab_collector::npages, file_ftab_collector::nsects, NULL, OLD_PAGE, vpid::pageid, file_ftab_collector::partsect_ftab, pgbuf_dealloc_page(), pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, vsid::sectid, SECTOR_FIRST_PAGEID, file_header::self, file_tempcache::spacedb_temp, TDE_ALGORITHM_NONE, tde_get_algorithm_name(), VFID_AS_ARGS, VFID_ISNULL, vpid::volid, vsid::volid, file_partial_sector::vsid, and file_vsid_collector::vsids.
Referenced by ehash_create_helper(), file_rv_destroy(), file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_temp_retire_internal(), file_tempcache_cache_or_drop_entries(), and xehash_destroy().
int file_dump | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE * | fp | ||
) |
Definition at line 7386 of file file_manager.c.
References ASSERT_ERROR, ASSERT_ERROR_AND_SET, FILE_GET_HEADER_VPID, file_header_dump(), file_table_dump(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, STATIC_INLINE, and VFID_AS_ARGS.
Referenced by file_tracker_item_dump(), and heap_dump().
|
static |
Definition at line 2736 of file file_manager.c.
References file_extdata_item_count(), NO_ERROR, and STATIC_INLINE.
Referenced by file_extdata_all_item_count().
|
static |
Definition at line 2720 of file file_manager.c.
References file_extdata_add_item_count(), file_extdata_apply_funcs(), and NULL.
Referenced by file_header_sanity_check().
STATIC_INLINE void file_extdata_append | ( | FILE_EXTENSIBLE_DATA * | extdata, |
const void * | append_data | ||
) |
Definition at line 1615 of file file_manager.c.
References assert, file_extdata_end(), file_extdata_is_full(), file_extensible_data::n_items, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_create(), file_numerable_add_page(), file_perm_dealloc(), file_perm_expand(), file_rv_perm_expand_redo(), and file_temp_alloc().
STATIC_INLINE void file_extdata_append_array | ( | FILE_EXTENSIBLE_DATA * | extdata, |
const void * | append_data, | ||
INT16 | count | ||
) |
Definition at line 1633 of file file_manager.c.
References assert, cubregex::count(), file_extdata_end(), file_extdata_remaining_capacity(), file_extensible_data::n_items, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_extdata_merge_unordered(), and file_table_move_partial_sectors_to_header().
|
static |
Definition at line 1882 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, file_extdata_at(), file_extdata_item_count(), i, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, pgbuf_get_vpid_ptr(), PGBUF_LATCH_READ, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, VPID_EQ, VPID_INITIALIZER, VPID_ISNULL, and file_extensible_data::vpid_next.
Referenced by file_apply_tde_algorithm(), file_destroy(), file_extdata_all_item_count(), file_extdata_search_item(), file_map_pages(), file_numerable_find_nth(), file_table_check(), file_table_collect_all_vsids(), file_table_collect_ftab_pages(), and file_table_dump().
STATIC_INLINE void * file_extdata_at | ( | const FILE_EXTENSIBLE_DATA * | extdata, |
int | index | ||
) |
Definition at line 1649 of file file_manager.c.
References assert, file_extdata_start(), file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_check_vpid(), file_create(), file_dealloc(), file_extdata_apply_funcs(), file_extdata_find_and_remove_item(), file_extdata_find_nth_vpid(), file_extdata_insert_at(), file_extdata_remove_at(), file_extdata_update_item(), file_log_extdata_remove(), file_perm_dealloc(), file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_rv_tracker_reuse_heap(), file_rv_user_page_unmark_delete_logical(), file_temp_alloc(), file_tracker_check(), file_tracker_interruptable_iterate(), file_tracker_item_dump(), file_tracker_item_dump_btree_capacity(), file_tracker_item_dump_capacity(), file_tracker_item_dump_heap(), file_tracker_item_dump_heap_capacity(), file_tracker_item_mark_heap_deleted(), file_tracker_item_reuse_heap(), and file_tracker_item_spacedb().
STATIC_INLINE bool file_extdata_can_merge | ( | const FILE_EXTENSIBLE_DATA * | extdata_src, |
const FILE_EXTENSIBLE_DATA * | extdata_dest | ||
) |
Definition at line 1664 of file file_manager.c.
References file_extdata_remaining_capacity(), file_extensible_data::n_items, and STATIC_INLINE.
Referenced by file_extdata_merge_pages().
|
static |
Definition at line 6981 of file file_manager.c.
References disk_compare_vsids(), FILE_EMPTY_PAGE_BITMAP, file_log, FILE_PARTSECT_AS_ARGS, FILE_PARTSECT_MSG, file_partsect_pageid_to_offset(), file_partsect_set_bit(), NO_ERROR, file_ftab_collector::npages, file_ftab_collector::nsects, file_partial_sector::page_bitmap, vpid::pageid, file_ftab_collector::partsect_ftab, STATIC_INLINE, VPID_AS_ARGS, VPID_ISNULL, file_extensible_data::vpid_next, file_partial_sector::vsid, VSID_AS_ARGS, and VSID_FROM_VPID.
Referenced by file_destroy(), and file_table_collect_ftab_pages().
STATIC_INLINE void * file_extdata_end | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1552 of file file_manager.c.
References file_extdata_size(), and STATIC_INLINE.
Referenced by file_create(), file_extdata_append(), file_extdata_append_array(), file_extdata_merge_ordered(), and file_temp_reset_user_pages().
|
static |
Definition at line 2567 of file file_manager.c.
References assert, ASSERT_ERROR_AND_SET, assert_release, ER_FAILED, FILE_EXTDATA_AS_ARGS, file_extdata_at(), file_extdata_find_ordered(), file_extdata_item_count(), file_extdata_merge_pages(), FILE_EXTDATA_MSG, file_extdata_remove_at(), file_log, file_log_extdata_remove(), log_check_system_op_is_started(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, pgbuf_get_lsa(), pgbuf_get_vpid(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, PGBUF_PAGE_MODIFY_MSG, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, file_extensible_data::size_of_item, VPID_ISNULL, file_extensible_data::vpid_next, and VPID_SET_NULL.
Referenced by file_perm_dealloc(), file_rv_dealloc_internal(), and file_tracker_unregister().
|
static |
Definition at line 2108 of file file_manager.c.
References assert, ASSERT_ERROR_AND_SET, file_extdata_is_full(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, VPID_COPY, and VPID_ISNULL.
Referenced by file_perm_dealloc(), file_table_add_full_sector(), and file_tracker_register_internal().
|
static |
Definition at line 7882 of file file_manager.c.
References assert, file_extdata_at(), file_extdata_item_count(), FILE_USER_PAGE_IS_MARKED_DELETED, file_find_nth_context::first_index, NO_ERROR, file_find_nth_context::nth, VPID_COPY, and file_find_nth_context::vpid_nth.
Referenced by file_numerable_find_nth().
|
static |
Definition at line 7916 of file file_manager.c.
References FILE_USER_PAGE_IS_MARKED_DELETED, NO_ERROR, file_find_nth_context::nth, and file_find_nth_context::vpid_nth.
Referenced by file_numerable_find_nth().
|
static |
Definition at line 1788 of file file_manager.c.
References assert, file_extdata_item_count(), file_extdata_start(), NULL, file_extensible_data::size_of_item, STATIC_INLINE, and util_bsearch().
Referenced by file_extdata_find_and_remove_item(), file_extdata_func_for_search_ordered(), file_perm_dealloc(), file_table_add_full_sector(), and file_tracker_register_internal().
|
static |
Definition at line 1991 of file file_manager.c.
References assert, file_extensible_data_search_context::compare_func, file_extdata_find_ordered(), file_extensible_data_search_context::found, file_extensible_data_search_context::item_to_find, NO_ERROR, NULL, and file_extensible_data_search_context::position.
Referenced by file_extdata_search_item().
STATIC_INLINE void file_extdata_init | ( | INT16 | item_size, |
INT16 | max_size, | ||
FILE_EXTENSIBLE_DATA * | extdata | ||
) |
Definition at line 1488 of file file_manager.c.
References assert, DB_ALIGN, DB_ALIGN_BELOW, FILE_EXTDATA_HEADER_ALIGNED_SIZE, MAX_ALIGNMENT, file_extensible_data::max_size, file_extensible_data::n_items, NULL, file_extensible_data::size_of_item, STATIC_INLINE, file_extensible_data::vpid_next, and VPID_SET_NULL.
Referenced by file_create(), file_numerable_add_page(), file_perm_dealloc(), file_table_append_full_sector_page(), file_temp_alloc(), and file_tracker_init_page().
STATIC_INLINE void file_extdata_insert_at | ( | FILE_EXTENSIBLE_DATA * | extdata, |
int | position, | ||
int | count, | ||
const void * | data | ||
) |
Definition at line 1808 of file file_manager.c.
References assert, cubregex::count(), file_extdata_at(), file_extdata_is_full(), file_extdata_item_count(), file_extensible_data::n_items, NULL, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_perm_dealloc(), file_rv_extdata_add(), file_table_add_full_sector(), and file_tracker_register_internal().
STATIC_INLINE bool file_extdata_is_empty | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1577 of file file_manager.c.
References assert, file_extensible_data::n_items, and STATIC_INLINE.
Referenced by file_create(), file_header_sanity_check(), file_perm_alloc(), file_rv_perm_expand_redo(), and file_table_move_partial_sectors_to_header().
STATIC_INLINE bool file_extdata_is_full | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1564 of file file_manager.c.
References assert, file_extensible_data::max_size, file_extensible_data::n_items, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_create(), file_extdata_append(), file_extdata_find_not_full(), file_extdata_insert_at(), file_numerable_add_page(), file_temp_alloc(), and file_tracker_register_internal().
STATIC_INLINE INT16 file_extdata_item_count | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1590 of file file_manager.c.
References file_extensible_data::n_items, and STATIC_INLINE.
Referenced by file_create(), file_extdata_add_item_count(), file_extdata_apply_funcs(), file_extdata_find_and_remove_item(), file_extdata_find_nth_vpid(), file_extdata_find_ordered(), file_extdata_insert_at(), file_extdata_merge_ordered(), file_extdata_merge_unordered(), file_numerable_add_page(), file_rv_perm_expand_undo(), file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone(), file_rv_tracker_reuse_heap(), file_table_move_partial_sectors_to_header(), file_temp_alloc(), file_tracker_interruptable_iterate(), and file_tracker_map().
|
static |
Definition at line 2020 of file file_manager.c.
References file_extensible_data_search_context::compare_func, file_extensible_data_search_context::found, file_extensible_data_search_context::item_to_find, NO_ERROR, and file_extensible_data_search_context::position.
Referenced by file_extdata_search_item().
STATIC_INLINE int file_extdata_max_size | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1516 of file file_manager.c.
References FILE_EXTDATA_HEADER_ALIGNED_SIZE, file_extensible_data::max_size, and STATIC_INLINE.
Referenced by file_create().
STATIC_INLINE void file_extdata_merge_ordered | ( | const FILE_EXTENSIBLE_DATA * | extdata_src, |
FILE_EXTENSIBLE_DATA * | extdata_dest, | ||
int(*)(const void *, const void *) | compare_func | ||
) |
Definition at line 1691 of file file_manager.c.
References assert, file_extdata_end(), file_extdata_item_count(), file_extdata_remaining_capacity(), file_extdata_start(), file_extensible_data::n_items, and file_extensible_data::size_of_item.
Referenced by file_extdata_merge_pages().
STATIC_INLINE bool file_extdata_merge_pages | ( | THREAD_ENTRY * | thread_p, |
const FILE_EXTENSIBLE_DATA * | extdata_src, | ||
const PAGE_PTR | page_src, | ||
FILE_EXTENSIBLE_DATA * | extdata_dest, | ||
PAGE_PTR | page_dest, | ||
int(*)(const void *, const void *) | compare_func, | ||
bool | ordered | ||
) |
Definition at line 2499 of file file_manager.c.
References assert, DB_PAGESIZE, DONT_FREE, FILE_EXTDATA_AS_ARGS, file_extdata_can_merge(), file_extdata_merge_ordered(), file_extdata_merge_unordered(), FILE_EXTDATA_MSG, file_extdata_size(), file_log, log_append_redo_data(), log_append_undo_data(), log_check_system_op_is_started(), LOG_DATA_ADDR_INITIALIZER, LSA_INITIALIZER, NULL, log_data_addr::offset, pgbuf_get_lsa(), PGBUF_PAGE_MODIFY_ARGS, PGBUF_PAGE_MODIFY_MSG, PGBUF_PAGE_STATE_ARGS, PGBUF_PAGE_STATE_MSG, pgbuf_set_dirty(), log_data_addr::pgptr, RVFL_EXTDATA_MERGE, and file_extensible_data::vpid_next.
Referenced by file_extdata_find_and_remove_item(), and file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone().
STATIC_INLINE void file_extdata_merge_unordered | ( | const FILE_EXTENSIBLE_DATA * | extdata_src, |
FILE_EXTENSIBLE_DATA * | extdata_dest | ||
) |
Definition at line 1677 of file file_manager.c.
References file_extdata_append_array(), file_extdata_item_count(), file_extdata_start(), and STATIC_INLINE.
Referenced by file_extdata_merge_pages().
STATIC_INLINE INT16 file_extdata_remaining_capacity | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1602 of file file_manager.c.
References file_extensible_data::max_size, file_extensible_data::n_items, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_extdata_append_array(), file_extdata_can_merge(), file_extdata_merge_ordered(), file_perm_expand(), and file_table_move_partial_sectors_to_header().
STATIC_INLINE void file_extdata_remove_at | ( | FILE_EXTENSIBLE_DATA * | extdata, |
int | position, | ||
int | count | ||
) |
Definition at line 1842 of file file_manager.c.
References assert_release, cubregex::count(), file_extdata_at(), if(), file_extensible_data::n_items, and file_extensible_data::size_of_item.
Referenced by file_create(), file_extdata_find_and_remove_item(), file_perm_alloc(), file_rv_extdata_remove(), and file_table_move_partial_sectors_to_header().
|
static |
Definition at line 2049 of file file_manager.c.
References assert, ASSERT_ERROR, file_extensible_data_search_context::compare_func, file_extdata_apply_funcs(), file_extdata_func_for_search_ordered(), file_extdata_item_func_for_search(), file_extensible_data_search_context::found, file_extensible_data_search_context::item_to_find, NO_ERROR, NULL, and file_extensible_data_search_context::position.
Referenced by file_check_vpid(), file_dealloc(), file_perm_dealloc(), file_rv_user_page_unmark_delete_logical(), file_tracker_apply_to_file(), and file_tracker_interruptable_iterate().
STATIC_INLINE int file_extdata_size | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1528 of file file_manager.c.
References FILE_EXTDATA_HEADER_ALIGNED_SIZE, file_extensible_data::n_items, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_create(), file_extdata_end(), file_extdata_merge_pages(), file_numerable_add_page(), file_perm_dealloc(), file_rv_extdata_merge(), and file_table_append_full_sector_page().
STATIC_INLINE void * file_extdata_start | ( | const FILE_EXTENSIBLE_DATA * | extdata | ) |
Definition at line 1540 of file file_manager.c.
References FILE_EXTDATA_HEADER_ALIGNED_SIZE, and STATIC_INLINE.
Referenced by file_create(), file_extdata_at(), file_extdata_find_ordered(), file_extdata_merge_ordered(), file_extdata_merge_unordered(), file_perm_alloc(), file_table_move_partial_sectors_to_header(), and file_temp_reset_user_pages().
STATIC_INLINE void file_extdata_update_item | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page_extdata, | ||
const void * | item_newval, | ||
int | index_item, | ||
FILE_EXTENSIBLE_DATA * | extdata | ||
) |
Definition at line 2473 of file file_manager.c.
References DONT_FREE, file_extdata_at(), log_append_undoredo_data2(), NULL, pgbuf_set_dirty(), RVFL_EXTDATA_UPDATE_ITEM, file_extensible_data::size_of_item, and STATIC_INLINE.
|
static |
Definition at line 5836 of file file_manager.c.
References NO_ERROR, pgbuf_set_tde_algorithm(), file_set_tde_algorithm_args::skip_logging, and file_set_tde_algorithm_args::tde_algo.
Referenced by file_apply_tde_algorithm().
|
static |
Definition at line 7554 of file file_manager.c.
References FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, and NO_ERROR.
Referenced by file_table_dump().
|
static |
Definition at line 7573 of file file_manager.c.
References DISK_SECTOR_NPAGES, NO_ERROR, vpid::pageid, vsid::sectid, SECTOR_FIRST_PAGEID, vpid::volid, vsid::volid, VPID_AS_ARGS, and VSID_AS_ARGS.
Referenced by file_table_dump().
int file_get_num_user_pages | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
int * | n_user_pages_out | ||
) |
Definition at line 6645 of file file_manager.c.
References ASSERT_ERROR_AND_SET, FILE_GET_HEADER_VPID, file_header_sanity_check(), file_header::n_page_user, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, and pgbuf_unfix.
Referenced by btree_get_stats(), catalog_dump(), catalog_reclaim_space(), ehash_dump(), ehash_expand_directory(), ehash_map(), ehash_shrink_directory(), heap_check_all_pages(), sort_checkalloc_numpages_of_outfiles(), xcache_check_recompilation_threshold(), xstats_get_statistics_from_server(), and xstats_update_statistics().
int file_get_sticky_first_page | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
VPID * | vpid_out | ||
) |
Definition at line 5630 of file file_manager.c.
References ASSERT_ERROR_AND_SET, assert_release, ER_FAILED, FILE_GET_HEADER_VPID, file_header_sanity_check(), LOG_ISRESTARTED, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, VPID_ISNULL, and file_header::vpid_sticky_first.
Referenced by btree_get_btid_from_file(), file_tracker_item_reuse_heap(), file_tracker_load(), heap_get_header_page(), and vacuum_get_first_page_dropped_files().
int file_get_tde_algorithm | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
PGBUF_LATCH_CONDITION | fix_head_cond, | ||
TDE_ALGORITHM * | tde_algo | ||
) |
Definition at line 5782 of file file_manager.c.
References ER_FAILED, FILE_GET_HEADER_VPID, file_get_tde_algorithm_internal(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, and pgbuf_unfix.
Referenced by log_append_sysop_end(), and sort_write_area().
|
static |
Definition at line 5816 of file file_manager.c.
References assert, FILE_FLAG_ENCRYPTED_AES, FILE_FLAG_ENCRYPTED_ARIA, file_header::file_flags, TDE_ALGORITHM_AES, TDE_ALGORITHM_ARIA, and TDE_ALGORITHM_NONE.
Referenced by file_alloc(), file_apply_tde_algorithm(), file_destroy(), file_get_tde_algorithm(), and file_set_tde_algorithm().
STATIC_INLINE int file_get_tempcache_entry_index | ( | THREAD_ENTRY * | thread_p | ) |
Definition at line 9365 of file file_manager.c.
References logtb_get_current_tran_index().
Referenced by file_get_tran_num_temp_files(), file_tempcache_drop_tran_temp_files(), file_tempcache_pop_tran_file(), and file_tempcache_push_tran_file().
int file_get_tran_num_temp_files | ( | THREAD_ENTRY * | thread_p | ) |
Definition at line 9494 of file file_manager.c.
References file_get_tempcache_entry_index(), file_tempcache_entry::next, NULL, STATIC_INLINE, and file_tempcache::tran_files.
Referenced by file_tempcache_drop_tran_temp_files(), and logtb_descriptors_start_scan().
int file_get_type | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE_TYPE * | ftype_out | ||
) |
Definition at line 6817 of file file_manager.c.
References assert, ASSERT_ERROR_AND_SET, FILE_GET_HEADER_VPID, file_header_sanity_check(), FILE_UNKNOWN_TYPE, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_header::type, and VFID_ISNULL.
Referenced by heap_check_heap_file(), heap_hfid_cache_get(), heap_scancache_reset_modify(), heap_scancache_start_internal(), vacuum_heap_get_hfid_and_file_type(), and xheap_destroy_newly_created().
STATIC_INLINE void file_header_alloc | ( | FILE_HEADER * | fhead, |
FILE_ALLOC_TYPE | alloc_type, | ||
bool | was_empty, | ||
bool | is_full | ||
) |
Definition at line 1090 of file file_manager.c.
References assert, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_TABLE_PAGE_FULL_SECTOR, FILE_ALLOC_USER_PAGE, file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_user, file_header::n_sector_empty, file_header::n_sector_full, file_header::n_sector_partial, NULL, and STATIC_INLINE.
Referenced by file_perm_alloc(), file_rv_fhead_alloc(), and file_temp_alloc().
STATIC_INLINE int file_header_copy | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
FILE_HEADER * | fhead_copy | ||
) |
Definition at line 1374 of file file_manager.c.
References ASSERT_ERROR_AND_SET, FILE_GET_HEADER_VPID, file_header_sanity_check(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, and STATIC_INLINE.
Referenced by file_tempcache_put().
STATIC_INLINE void file_header_dealloc | ( | FILE_HEADER * | fhead, |
FILE_ALLOC_TYPE | alloc_type, | ||
bool | is_empty, | ||
bool | was_full | ||
) |
Definition at line 1129 of file file_manager.c.
References assert, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_USER_PAGE, file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_user, file_header::n_sector_empty, file_header::n_sector_full, file_header::n_sector_partial, and NULL.
Referenced by file_perm_dealloc(), and file_rv_fhead_dealloc().
STATIC_INLINE void file_header_dump | ( | THREAD_ENTRY * | thread_p, |
const FILE_HEADER * | fhead, | ||
FILE * | fp | ||
) |
Definition at line 1406 of file file_manager.c.
References FILE_HEAD_FULL_AS_ARGS, FILE_HEAD_FULL_MSG, file_header_dump_descriptor(), and STATIC_INLINE.
Referenced by file_dump().
STATIC_INLINE void file_header_dump_descriptor | ( | THREAD_ENTRY * | thread_p, |
const FILE_HEADER * | fhead, | ||
FILE * | fp | ||
) |
Definition at line 1421 of file file_manager.c.
References file_btree_des::attr_id, file_ehash_des::attr_id, file_ovf_btree_des::btid, BTID_AS_ARGS, file_descriptors::btree, file_descriptors::btree_key_overflow, file_heap_des::class_oid, file_btree_des::class_oid, file_ehash_des::class_oid, file_header::descriptor, file_descriptors::ehash, FILE_BTREE, FILE_BTREE_OVERFLOW_KEY, FILE_CATALOG, FILE_DROPPED_FILES, FILE_EXTENDIBLE_HASH, FILE_EXTENDIBLE_HASH_DIRECTORY, FILE_HEAP, FILE_HEAP_REUSE_SLOTS, FILE_MULTIPAGE_OBJECT_HEAP, file_print_name_of_class(), FILE_QUERY_AREA, FILE_TEMP, FILE_TRACKER, FILE_UNKNOWN_TYPE, FILE_VACUUM_DATA, file_descriptors::heap, heap_get_indexinfo_of_btid(), file_descriptors::heap_overflow, file_ovf_heap_des::hfid, HFID_AS_ARGS, NO_ERROR, NULL, vpid::pageid, btid::root_pageid, file_header::self, STATIC_INLINE, file_header::type, btid::vfid, and file_header::vpid_sticky_first.
Referenced by file_descriptor_dump(), file_header_dump(), and file_tracker_item_dump_capacity().
STATIC_INLINE void file_header_init | ( | FILE_HEADER * | fhead | ) |
Definition at line 885 of file file_manager.c.
References file_tablespace::expand_max_size, file_tablespace::expand_min_size, file_tablespace::expand_ratio, file_header::file_flags, FILE_UNKNOWN_TYPE, file_header::first_index_find_nth_last, file_tablespace::initial_size, file_header::n_page_ftab, file_header::n_page_mark_delete, file_header::n_page_total, file_header::n_page_user, file_header::n_sector_empty, file_header::n_sector_full, file_header::n_sector_partial, file_header::n_sector_total, NULL_OFFSET, NULL_VOLDES, file_header::offset_to_full_ftab, file_header::offset_to_last_temp_alloc, file_header::offset_to_partial_ftab, file_header::offset_to_user_page_ftab, file_header::reserved0, file_header::reserved1, file_header::reserved2, file_header::reserved3, file_header::self, STATIC_INLINE, file_header::tablespace, file_header::time_creation, file_header::type, VFID_SET_NULL, file_header::volid_last_expand, file_header::vpid_find_nth_last, file_header::vpid_last_temp_alloc, file_header::vpid_last_user_page_ftab, VPID_SET_NULL, and file_header::vpid_sticky_first.
STATIC_INLINE void file_header_sanity_check | ( | THREAD_ENTRY * | thread_p, |
FILE_HEADER * | fhead | ||
) |
Definition at line 933 of file file_manager.c.
References assert, ASSERT_ERROR, db_private_free, disk_compare_vsids(), er_stack_pop(), er_stack_push(), file_extdata_all_item_count(), file_extdata_is_empty(), FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_table_collect_all_vsids(), file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_mark_delete, file_header::n_page_total, file_header::n_page_user, file_header::n_sector_empty, file_header::n_sector_full, file_header::n_sector_partial, file_header::n_sector_total, file_vsid_collector::n_vsids, NO_ERROR, NULL, pgbuf_has_any_waiters(), prm_get_bool_value(), PRM_ID_FILE_LOGGING, PRM_ID_FORCE_RESTART_TO_SKIP_RECOVERY, file_header::self, VFID_ISNULL, VPID_ISNULL, file_extensible_data::vpid_next, and file_vsid_collector::vsids.
Referenced by file_alloc(), file_alloc_multiple(), file_alloc_sticky_first_page(), file_apply_tde_algorithm(), file_check_vpid(), file_create(), file_descriptor_dump(), file_descriptor_get(), file_descriptor_update(), file_get_num_user_pages(), file_get_sticky_first_page(), file_get_type(), file_header_copy(), file_is_temp(), file_map_pages(), file_numerable_find_nth(), file_rv_dealloc_internal(), file_set_tde_algorithm(), file_table_check(), file_temp_alloc(), file_temp_reset_user_pages(), file_temp_set_type(), file_tracker_get_and_protect(), file_tracker_item_dump_capacity(), and file_tracker_item_reuse_heap().
STATIC_INLINE void file_header_update_mark_deleted | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page_fhead, | ||
int | delta | ||
) |
Definition at line 1314 of file file_manager.c.
References DONT_FREE, FILE_IS_TEMPORARY, file_log, log_append_undoredo_data2(), file_header::n_page_mark_delete, NULL, pgbuf_get_lsa(), PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), RVFL_FHEAD_MARK_DELETE, file_header::self, and VFID_AS_ARGS.
Referenced by file_dealloc(), and file_rv_dealloc_internal().
int file_init_page_type | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page, | ||
void * | args | ||
) |
Definition at line 5200 of file file_manager.c.
References file_init_page_type_internal().
Referenced by ehash_create_helper(), heap_create_internal(), overflow_insert(), overflow_update(), vacuum_add_dropped_file(), vacuum_consume_buffer_log_blocks(), vacuum_create_file_for_dropped_files(), and vacuum_create_file_for_vacuum_data().
STATIC_INLINE int file_init_page_type_internal | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page, | ||
PAGE_TYPE | ptype, | ||
bool | is_temp | ||
) |
Definition at line 5233 of file file_manager.c.
References DONT_FREE, log_append_undoredo_data2(), NO_ERROR, NULL, pgbuf_set_dirty(), pgbuf_set_page_ptype(), and RVPGBUF_NEW_PAGE.
Referenced by file_init_page_type(), and file_init_temp_page_type().
int file_init_temp_page_type | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page, | ||
void * | args | ||
) |
Definition at line 5216 of file file_manager.c.
References file_init_page_type_internal(), and STATIC_INLINE.
Referenced by ehash_create_helper(), and overflow_insert().
int file_is_temp | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
bool * | is_temp | ||
) |
Definition at line 6857 of file file_manager.c.
References assert, ASSERT_ERROR_AND_SET, FILE_GET_HEADER_VPID, file_header_sanity_check(), FILE_IS_TEMPORARY, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, STATIC_INLINE, and VFID_ISNULL.
Referenced by ehash_delete(), and ehash_insert_helper().
STATIC_INLINE void file_log_extdata_add | ( | THREAD_ENTRY * | thread_p, |
const FILE_EXTENSIBLE_DATA * | extdata, | ||
PAGE_PTR | page, | ||
int | position, | ||
int | count, | ||
const void * | data | ||
) |
Definition at line 2338 of file file_manager.c.
References cubregex::count(), log_crumb::data, DONT_FREE, log_crumb::length, log_append_undoredo_crumbs(), LOG_DATA_ADDR_INITIALIZER, log_data_addr::offset, pgbuf_set_dirty(), log_data_addr::pgptr, RVFL_EXTDATA_ADD, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_numerable_add_page(), file_perm_dealloc(), file_table_add_full_sector(), file_table_move_partial_sectors_to_header(), and file_tracker_register_internal().
STATIC_INLINE void file_log_extdata_remove | ( | THREAD_ENTRY * | thread_p, |
const FILE_EXTENSIBLE_DATA * | extdata, | ||
PAGE_PTR | page, | ||
int | position, | ||
int | count | ||
) |
Definition at line 2371 of file file_manager.c.
References cubregex::count(), log_crumb::data, DONT_FREE, file_extdata_at(), log_crumb::length, log_append_undoredo_crumbs(), LOG_DATA_ADDR_INITIALIZER, log_data_addr::offset, pgbuf_set_dirty(), log_data_addr::pgptr, RVFL_EXTDATA_REMOVE, file_extensible_data::size_of_item, and STATIC_INLINE.
Referenced by file_extdata_find_and_remove_item(), file_perm_alloc(), and file_table_move_partial_sectors_to_header().
STATIC_INLINE void file_log_extdata_set_next | ( | THREAD_ENTRY * | thread_p, |
const FILE_EXTENSIBLE_DATA * | extdata, | ||
PAGE_PTR | page, | ||
const VPID * | vpid_next | ||
) |
Definition at line 2403 of file file_manager.c.
References assert, DB_PAGESIZE, DONT_FREE, FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, file_log, log_append_undoredo_data(), LOG_DATA_ADDR_INITIALIZER, log_data_addr::offset, pgbuf_get_lsa(), PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), log_data_addr::pgptr, RVFL_EXTDATA_SET_NEXT, VPID_AS_ARGS, and file_extensible_data::vpid_next.
Referenced by file_numerable_add_page(), file_perm_dealloc(), file_table_append_full_sector_page(), file_table_move_partial_sectors_to_header(), and file_tracker_register_internal().
STATIC_INLINE void file_log_fhead_alloc | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page_fhead, | ||
FILE_ALLOC_TYPE | alloc_type, | ||
bool | was_empty, | ||
bool | is_full | ||
) |
Definition at line 1245 of file file_manager.c.
References assert, DONT_FREE, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_TABLE_PAGE_FULL_SECTOR, FILE_ALLOC_USER_PAGE, log_append_undoredo_data(), LOG_DATA_ADDR_INITIALIZER, NULL, pgbuf_set_dirty(), log_data_addr::pgptr, RVFL_FHEAD_ALLOC, and STATIC_INLINE.
Referenced by file_perm_alloc().
STATIC_INLINE void file_log_fhead_dealloc | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page_fhead, | ||
FILE_ALLOC_TYPE | alloc_type, | ||
bool | is_empty, | ||
bool | was_full | ||
) |
Definition at line 1281 of file file_manager.c.
References assert, DONT_FREE, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_USER_PAGE, log_append_undoredo_data(), LOG_DATA_ADDR_INITIALIZER, NULL, pgbuf_set_dirty(), log_data_addr::pgptr, RVFL_FHEAD_DEALLOC, and STATIC_INLINE.
Referenced by file_perm_dealloc().
void file_manager_final | ( | void | ) |
Definition at line 869 of file file_manager.c.
References file_tempcache_final(), and STATIC_INLINE.
Referenced by logtb_undefine_trantable().
int file_map_pages | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
PGBUF_LATCH_MODE | latch_mode, | ||
PGBUF_LATCH_CONDITION | latch_cond, | ||
FILE_MAP_PAGE_FUNC | func, | ||
void * | args | ||
) |
Definition at line 7164 of file file_manager.c.
References file_map_context::args, assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, db_private_free, file_extdata_apply_funcs(), FILE_GET_HEADER_VPID, FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, file_header_sanity_check(), FILE_IS_TEMPORARY, file_sector_map_pages(), file_table_collect_ftab_pages(), file_map_context::ftab_collector, file_map_context::func, file_map_context::is_partial, file_map_context::latch_cond, file_map_context::latch_mode, NO_ERROR, NULL, OLD_PAGE, file_ftab_collector::partsect_ftab, PGBUF_CONDITIONAL_LATCH, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_map_context::stop, and VFID_ISNULL.
Referenced by catalog_dump(), catalog_find_optimal_page(), catalog_reclaim_space(), and heap_check_all_pages_by_heapchain().
|
static |
Definition at line 7698 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, DB_PAGESIZE, DONT_FREE, FILE_ALLOC_TABLE_PAGE, file_extdata_append(), FILE_EXTDATA_AS_ARGS, file_extdata_init(), file_extdata_is_full(), file_extdata_item_count(), FILE_EXTDATA_MSG, file_extdata_size(), FILE_GET_HEADER_VPID, FILE_HEAD_FULL_AS_ARGS, FILE_HEAD_FULL_MSG, FILE_HEADER_GET_USER_PAGE_FTAB, FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_log, file_log_extdata_add(), file_log_extdata_set_next(), file_perm_alloc(), file_temp_alloc(), log_append_undoredo_data2(), NEW_PAGE, NO_ERROR, NULL, OLD_PAGE, PAGE_FTAB, pgbuf_fix, pgbuf_get_lsa(), PGBUF_LATCH_WRITE, pgbuf_log_new_page(), PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), pgbuf_set_dirty_and_free, pgbuf_set_page_ptype(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, RVFL_FHEAD_SET_LAST_USER_PAGE_FTAB, file_header::self, VFID_AS_ARGS, VPID_AS_ARGS, VPID_COPY, VPID_EQ, VPID_INITIALIZER, VPID_ISNULL, file_header::vpid_last_user_page_ftab, and file_extensible_data::vpid_next.
Referenced by file_alloc().
int file_numerable_find_nth | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
int | nth, | ||
bool | auto_alloc, | ||
FILE_INIT_PAGE_FUNC | f_init, | ||
void * | f_init_args, | ||
VPID * | vpid_nth | ||
) |
Definition at line 7956 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, ER_FAILED, ER_PAGE_LATCH_PROMOTE_FAIL, file_alloc(), FILE_CACHE_LAST_FIND_NTH, file_extdata_apply_funcs(), file_extdata_find_nth_vpid(), file_extdata_find_nth_vpid_and_skip_marked(), FILE_GET_HEADER_VPID, FILE_HEADER_GET_USER_PAGE_FTAB, file_header_sanity_check(), FILE_IS_NUMERABLE, file_log, file_find_nth_context::first_index, file_header::first_index_find_nth_last, file_header::n_page_mark_delete, file_header::n_page_user, NO_ERROR, file_find_nth_context::nth, NULL, OLD_PAGE, pgbuf_fix, pgbuf_get_vpid(), PGBUF_LATCH_READ, PGBUF_LATCH_WRITE, pgbuf_promote_read_latch, PGBUF_PROMOTE_SHARED_READER, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, VFID_AS_ARGS, VFID_ISNULL, VPID_AS_ARGS, VPID_EQ, file_header::vpid_find_nth_last, VPID_ISNULL, file_find_nth_context::vpid_nth, and VPID_SET_NULL.
Referenced by ehash_fix_nth_page(), file_numerable_truncate(), sort_read_area(), and sort_write_area().
int file_numerable_truncate | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
DKNPAGES | npages | ||
) |
Definition at line 8340 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, ER_FAILED, file_dealloc(), FILE_GET_HEADER_VPID, FILE_IS_NUMERABLE, file_numerable_find_nth(), file_header::n_page_mark_delete, file_header::n_page_user, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, and file_header::type.
Referenced by ehash_shrink_directory().
|
static |
Definition at line 7479 of file file_manager.c.
References FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, and NO_ERROR.
Referenced by file_table_dump().
|
static |
Definition at line 7498 of file file_manager.c.
References DISK_SECTOR_NPAGES, FILE_PARTSECT_AS_ARGS, file_partsect_is_bit_set(), FILE_PARTSECT_MSG, NO_ERROR, vpid::pageid, vsid::sectid, SECTOR_FIRST_PAGEID, vpid::volid, vsid::volid, VPID_AS_ARGS, and file_partial_sector::vsid.
Referenced by file_table_dump().
STATIC_INLINE bool file_partsect_alloc | ( | FILE_PARTIAL_SECTOR * | partsect, |
VPID * | vpid_out, | ||
int * | offset_out | ||
) |
Definition at line 2843 of file file_manager.c.
References assert, bit64_count_trailing_ones(), FILE_ALLOC_BITMAP_NBITS, file_partsect_is_full(), file_partsect_set_bit(), file_partial_sector::page_bitmap, vpid::pageid, vsid::sectid, SECTOR_FIRST_PAGEID, vpid::volid, vsid::volid, and file_partial_sector::vsid.
Referenced by file_perm_alloc(), and file_temp_alloc().
STATIC_INLINE void file_partsect_clear_bit | ( | FILE_PARTIAL_SECTOR * | partsect, |
int | offset | ||
) |
Definition at line 2807 of file file_manager.c.
References assert, bit64_clear(), file_partsect_is_bit_set(), file_partial_sector::page_bitmap, and STATIC_INLINE.
Referenced by file_perm_dealloc(), and file_rv_partsect_update().
STATIC_INLINE bool file_partsect_is_bit_set | ( | FILE_PARTIAL_SECTOR * | partsect, |
int | offset | ||
) |
Definition at line 2779 of file file_manager.c.
References bit64_is_set(), file_partial_sector::page_bitmap, and STATIC_INLINE.
Referenced by file_check_vpid(), file_create(), file_destroy(), file_partial_table_item_dump(), file_partsect_clear_bit(), file_partsect_set_bit(), file_perm_alloc(), file_sector_map_dealloc(), file_sector_map_pages(), and file_table_collector_has_page().
STATIC_INLINE bool file_partsect_is_empty | ( | FILE_PARTIAL_SECTOR * | partsect | ) |
Definition at line 2766 of file file_manager.c.
References FILE_EMPTY_PAGE_BITMAP, file_partial_sector::page_bitmap, and STATIC_INLINE.
Referenced by file_perm_alloc(), file_perm_dealloc(), and file_temp_alloc().
STATIC_INLINE bool file_partsect_is_full | ( | FILE_PARTIAL_SECTOR * | partsect | ) |
Definition at line 2754 of file file_manager.c.
References FILE_FULL_PAGE_BITMAP, file_partial_sector::page_bitmap, and STATIC_INLINE.
Referenced by file_create(), file_partsect_alloc(), file_perm_alloc(), and file_temp_alloc().
STATIC_INLINE int file_partsect_pageid_to_offset | ( | FILE_PARTIAL_SECTOR * | partsect, |
PAGEID | pageid | ||
) |
Definition at line 2822 of file file_manager.c.
References assert, vsid::sectid, SECTOR_FIRST_PAGEID, SECTOR_FROM_PAGEID, STATIC_INLINE, and file_partial_sector::vsid.
Referenced by file_check_vpid(), file_create(), file_extdata_collect_ftab_pages(), file_perm_dealloc(), file_table_collect_ftab_pages(), and file_table_collector_has_page().
STATIC_INLINE void file_partsect_set_bit | ( | FILE_PARTIAL_SECTOR * | partsect, |
int | offset | ||
) |
Definition at line 2792 of file file_manager.c.
References assert, bit64_set(), file_partsect_is_bit_set(), file_partial_sector::page_bitmap, and STATIC_INLINE.
Referenced by file_create(), file_extdata_collect_ftab_pages(), file_partsect_alloc(), file_rv_partsect_update(), file_table_collect_ftab_pages(), and file_temp_alloc().
|
static |
Definition at line 5017 of file file_manager.c.
References assert, ASSERT_ERROR, assert_release, ER_FAILED, FILE_ALLOC_TABLE_PAGE_FULL_SECTOR, FILE_ALLOC_TYPE_STRING, FILE_EXTDATA_AS_ARGS, file_extdata_is_empty(), FILE_EXTDATA_MSG, file_extdata_remove_at(), file_extdata_start(), FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, file_header_alloc(), FILE_HEADER_GET_PART_FTAB, file_log, file_log_extdata_remove(), file_log_fhead_alloc(), file_partsect_alloc(), FILE_PARTSECT_AS_ARGS, file_partsect_is_bit_set(), file_partsect_is_empty(), file_partsect_is_full(), FILE_PARTSECT_MSG, file_perm_expand(), file_table_add_full_sector(), file_table_append_full_sector_page(), file_table_move_partial_sectors_to_header(), log_append_undoredo_data2(), log_check_system_op_is_started(), file_header::n_page_free, file_header::n_sector_partial, NO_ERROR, NULL, perfmon_inc_stat(), pgbuf_get_lsa(), PGBUF_PAGE_MODIFY_ARGS, PSTAT_FILE_NUM_PAGE_ALLOCS, RVFL_PARTSECT_ALLOC, file_header::self, VFID_AS_ARGS, VPID_AS_ARGS, VPID_ISNULL, and file_partial_sector::vsid.
Referenced by file_alloc(), file_numerable_add_page(), file_perm_dealloc(), and file_table_add_full_sector().
|
static |
Definition at line 6165 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, DB_PAGESIZE, disk_compare_vsids(), DONT_FREE, ER_FAILED, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_TYPE_STRING, file_extdata_append(), FILE_EXTDATA_AS_ARGS, file_extdata_at(), file_extdata_find_and_remove_item(), file_extdata_find_not_full(), file_extdata_find_ordered(), file_extdata_init(), file_extdata_insert_at(), FILE_EXTDATA_MSG, file_extdata_search_item(), file_extdata_size(), FILE_FULL_PAGE_BITMAP, FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, file_header_dealloc(), FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_log, file_log_extdata_add(), file_log_extdata_set_next(), file_log_fhead_dealloc(), FILE_PARTSECT_AS_ARGS, file_partsect_clear_bit(), file_partsect_is_empty(), FILE_PARTSECT_MSG, file_partsect_pageid_to_offset(), file_perm_alloc(), log_append_undoredo_data(), log_check_system_op_is_started(), LOG_DATA_ADDR_INITIALIZER, NEW_PAGE, NO_ERROR, NULL, log_data_addr::offset, OLD_PAGE, file_partial_sector::page_bitmap, PAGE_FTAB, vpid::pageid, perfmon_inc_stat(), pgbuf_dealloc_page(), pgbuf_fix, pgbuf_get_lsa(), PGBUF_LATCH_WRITE, pgbuf_log_new_page(), PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), pgbuf_set_page_ptype(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, log_data_addr::pgptr, PSTAT_FILE_NUM_PAGE_DEALLOCS, RVFL_PARTSECT_DEALLOC, vsid::sectid, SECTOR_FROM_PAGEID, file_header::self, VFID_AS_ARGS, vpid::volid, vsid::volid, VPID_AS_ARGS, VPID_COPY, VPID_EQ, VPID_INITIALIZER, VPID_ISNULL, file_extensible_data::vpid_next, file_header::vpid_sticky_first, file_partial_sector::vsid, VSID_AS_ARGS, and VSID_IS_SECTOR_OF_VPID.
Referenced by file_rv_dealloc_internal().
|
static |
Definition at line 4495 of file file_manager.c.
References ARG_FILE_LINE, assert, ASSERT_ERROR, DB_PERMANENT_DATA_PURPOSE, db_private_alloc, db_private_free, DB_SECTORSIZE, disk_compare_vsids(), disk_reserve_sectors(), DISK_SECTOR_NPAGES, DONT_FREE, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), file_tablespace::expand_max_size, file_tablespace::expand_min_size, file_tablespace::expand_ratio, FILE_EMPTY_PAGE_BITMAP, file_extdata_append(), FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, file_extdata_remaining_capacity(), FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_log, FILE_TABLESPACE_AS_ARGS, FILE_TABLESPACE_MSG, log_append_undoredo_data2(), log_check_system_op_is_started(), log_sysop_abort(), log_sysop_commit(), log_sysop_start(), file_header::n_page_free, file_header::n_page_total, file_header::n_sector_empty, file_header::n_sector_partial, file_header::n_sector_total, NO_ERROR, NULL, file_partial_sector::page_bitmap, pgbuf_get_lsa(), PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), RVFL_EXPAND, file_header::self, file_header::tablespace, VFID_AS_ARGS, file_header::volid_last_expand, file_partial_sector::vsid, and VSID_AS_ARGS.
Referenced by file_perm_alloc().
void file_postpone_destroy | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid | ||
) |
Definition at line 4263 of file file_manager.c.
References assert, ASSERT_ERROR, FILE_IS_TEMPORARY, vfid::fileid, log_append_postpone(), LOG_DATA_ADDR_INITIALIZER, NULL, OLD_PAGE, vpid::pageid, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, RVFL_DESTROY, vpid::volid, and vfid::volid.
Referenced by ehash_create_helper(), xbtree_delete_index(), xheap_destroy(), and xheap_destroy_newly_created().
|
static |
Definition at line 3062 of file file_manager.c.
References er_clear(), free_and_init, heap_get_class_name(), NO_ERROR, NULL, OID_AS_ARGS, and OID_ISNULL.
Referenced by file_header_dump_descriptor().
|
static |
Definition at line 6472 of file file_manager.c.
References assert, ASSERT_ERROR, assert_release, log_rcv::data, ER_FAILED, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_USER_PAGE, file_compare_vpids(), file_extdata_find_and_remove_item(), FILE_GET_HEADER_VPID, FILE_HEADER_GET_USER_PAGE_FTAB, file_header_sanity_check(), file_header_update_mark_deleted(), FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_perm_dealloc(), FILE_RV_DEALLOC_COMPENSATE, FILE_USER_PAGE_IS_MARKED_DELETED, log_rcv::length, log_sysop_abort(), log_sysop_end_logical_compensate(), log_sysop_end_logical_run_postpone(), log_sysop_start_atomic(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, log_rcv::reference_lsa, VPID_INITIALIZER, and VPID_ISNULL.
Referenced by file_rv_dealloc_on_postpone(), and file_rv_dealloc_on_undo().
int file_rv_dealloc_on_postpone | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 6629 of file file_manager.c.
References file_log, file_rv_dealloc_internal(), FILE_RV_DEALLOC_RUN_POSTPONE, LSA_AS_ARGS, and log_rcv::reference_lsa.
int file_rv_dealloc_on_undo | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 6614 of file file_manager.c.
References file_log, FILE_RV_DEALLOC_COMPENSATE, file_rv_dealloc_internal(), LSA_AS_ARGS, and log_rcv::reference_lsa.
int file_rv_destroy | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 4233 of file file_manager.c.
References assert, assert_release, log_rcv::data, file_destroy(), log_rcv::length, log_check_system_op_is_started(), and NO_ERROR.
void file_rv_dump_extdata_add | ( | FILE * | fp, |
int | length, | ||
void * | data | ||
) |
Definition at line 2289 of file file_manager.c.
References cubregex::count(), and log_rv_dump_hexa().
void file_rv_dump_extdata_remove | ( | FILE * | fp, |
int | length, | ||
void * | data | ||
) |
Definition at line 2312 of file file_manager.c.
References assert, cubregex::count(), and STATIC_INLINE.
void file_rv_dump_extdata_set_next | ( | FILE * | fp, |
int | ignore_length, | ||
void * | data | ||
) |
Definition at line 2197 of file file_manager.c.
References VPID_AS_ARGS.
void file_rv_dump_vfid_and_vpid | ( | FILE * | fp, |
int | length, | ||
void * | data | ||
) |
Definition at line 4989 of file file_manager.c.
References assert, NULL, VFID_AS_ARGS, and VPID_AS_ARGS.
int file_rv_extdata_add | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 2212 of file file_manager.c.
References assert, cubregex::count(), log_rcv::data, DB_PAGESIZE, DONT_FREE, FILE_EXTDATA_AS_ARGS, file_extdata_insert_at(), FILE_EXTDATA_MSG, file_log, log_rcv::length, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, and file_extensible_data::size_of_item.
int file_rv_extdata_merge | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 2435 of file file_manager.c.
References assert, log_rcv::data, DB_PAGESIZE, DONT_FREE, FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, file_extdata_size(), file_log, log_rcv::length, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, PGBUF_PAGE_STATE_MSG, pgbuf_set_dirty(), log_rcv::pgptr, and STATIC_INLINE.
int file_rv_extdata_remove | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 2249 of file file_manager.c.
References assert, cubregex::count(), log_rcv::data, DB_PAGESIZE, DONT_FREE, FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, file_extdata_remove_at(), file_log, log_rcv::length, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), and log_rcv::pgptr.
int file_rv_extdata_set_next | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 2167 of file file_manager.c.
References assert, log_rcv::data, DB_PAGESIZE, DONT_FREE, FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, file_log, log_rcv::length, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, VPID_COPY, and file_extensible_data::vpid_next.
int file_rv_fhead_alloc | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 1165 of file file_manager.c.
References assert, log_rcv::data, DONT_FREE, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_TYPE_STRING, FILE_ALLOC_USER_PAGE, FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, file_header_alloc(), file_log, log_rcv::length, NO_ERROR, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, file_header::self, and VFID_AS_ARGS.
int file_rv_fhead_convert_ftab_to_user_page | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 4786 of file file_manager.c.
References DONT_FREE, file_header::n_page_ftab, file_header::n_page_user, NO_ERROR, pgbuf_set_dirty(), and log_rcv::pgptr.
int file_rv_fhead_convert_user_to_ftab_page | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 4806 of file file_manager.c.
References DONT_FREE, file_header::n_page_ftab, file_header::n_page_user, NO_ERROR, pgbuf_set_dirty(), and log_rcv::pgptr.
int file_rv_fhead_dealloc | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 1203 of file file_manager.c.
References assert, log_rcv::data, DONT_FREE, FILE_ALLOC_TABLE_PAGE, FILE_ALLOC_TYPE_STRING, FILE_ALLOC_USER_PAGE, FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, file_header_dealloc(), file_log, log_rcv::length, NO_ERROR, PGBUF_PAGE_LSA_AS_ARGS, PGBUF_PAGE_VPID_AS_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, file_header::self, STATIC_INLINE, and VFID_AS_ARGS.
int file_rv_fhead_set_last_user_page_ftab | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 1056 of file file_manager.c.
References assert, log_rcv::data, DONT_FREE, file_log, log_rcv::length, NO_ERROR, NULL, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, STATIC_INLINE, VFID_AS_ARGS, VPID_AS_ARGS, and VPID_COPY.
int file_rv_fhead_sticky_page | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 5604 of file file_manager.c.
References assert, log_rcv::data, DONT_FREE, file_log, log_rcv::length, NO_ERROR, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, file_header::self, VFID_AS_ARGS, VPID_AS_ARGS, and file_header::vpid_sticky_first.
int file_rv_header_update_mark_deleted | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 1344 of file file_manager.c.
References assert, log_rcv::data, DONT_FREE, file_log, log_rcv::length, NO_ERROR, NULL, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, STATIC_INLINE, and VFID_AS_ARGS.
int file_rv_partsect_clear | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 2933 of file file_manager.c.
References file_rv_partsect_update().
int file_rv_partsect_set | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 2920 of file file_manager.c.
References file_rv_partsect_update().
|
static |
Definition at line 2879 of file file_manager.c.
References assert, log_rcv::data, DB_PAGESIZE, DONT_FREE, file_log, FILE_PARTSECT_AS_ARGS, file_partsect_clear_bit(), FILE_PARTSECT_MSG, file_partsect_set_bit(), log_rcv::length, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), and log_rcv::pgptr.
Referenced by file_rv_partsect_clear(), and file_rv_partsect_set().
int file_rv_perm_expand_redo | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 4436 of file file_manager.c.
References assert, log_rcv::data, DISK_SECTOR_NPAGES, DONT_FREE, FILE_EMPTY_PAGE_BITMAP, file_extdata_append(), FILE_EXTDATA_AS_ARGS, file_extdata_is_empty(), FILE_EXTDATA_MSG, FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_log, log_rcv::length, file_header::n_page_free, file_header::n_page_total, file_header::n_sector_empty, file_header::n_sector_partial, file_header::n_sector_total, NO_ERROR, file_partial_sector::page_bitmap, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, file_header::self, VFID_AS_ARGS, and file_partial_sector::vsid.
int file_rv_perm_expand_undo | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 4387 of file file_manager.c.
References assert, DISK_SECTOR_NPAGES, DONT_FREE, file_extdata_item_count(), FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_log, file_extensible_data::n_items, file_header::n_page_free, file_header::n_page_total, file_header::n_sector_empty, file_header::n_sector_partial, file_header::n_sector_total, NO_ERROR, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, file_header::self, VFID_AS_ARGS, VPID_ISNULL, and file_extensible_data::vpid_next.
int file_rv_set_tde_algorithm | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 5724 of file file_manager.c.
References assert, log_rcv::data, DONT_FREE, file_set_tde_algorithm_internal(), log_rcv::length, NO_ERROR, pgbuf_set_dirty(), and log_rcv::pgptr.
int file_rv_tracker_mark_heap_deleted | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv, | ||
bool | is_undo | ||
) |
Definition at line 10324 of file file_manager.c.
References assert, assert_release, log_rcv::data, file_tracker_apply_to_file(), file_tracker_item_mark_heap_deleted(), log_rcv::length, LSA_ISNULL(), NO_ERROR, PGBUF_LATCH_WRITE, and log_rcv::reference_lsa.
Referenced by heap_rv_mark_deleted_on_postpone(), and heap_rv_mark_deleted_on_undo().
int file_rv_tracker_mark_heap_deleted_compensate_or_run_postpone | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 10355 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, DONT_FREE, file_compare_track_items(), file_dealloc(), file_destroy(), file_extdata_at(), file_extdata_item_count(), file_extdata_merge_pages(), FILE_HEAP, file_log, FILE_TRACK_ITEM_AS_ARGS, FILE_TRACK_ITEM_MSG, FILE_TRACKER, file_track_item::fileid, vfid::fileid, file_track_metadata::heap, file_track_heap_metadata::is_marked_deleted, log_rcv::length, log_check_system_op_is_started(), log_sysop_abort(), log_sysop_commit(), log_sysop_start(), file_track_item::metadata, NO_ERROR, NULL, log_rcv::offset, OLD_PAGE, pgbuf_fix, pgbuf_get_vpid(), PGBUF_LATCH_WRITE, PGBUF_PAGE_STATE_ARGS, PGBUF_PAGE_STATE_MSG, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, log_rcv::pgptr, STATIC_INLINE, file_track_item::type, VFID_ISNULL, file_track_item::volid, vfid::volid, VPID_ISNULL, and file_extensible_data::vpid_next.
int file_rv_tracker_reuse_heap | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 10089 of file file_manager.c.
References assert, DONT_FREE, file_extdata_at(), file_extdata_item_count(), FILE_HEAP, file_log, FILE_TRACK_ITEM_AS_ARGS, FILE_TRACK_ITEM_MSG, file_track_metadata::heap, file_track_heap_metadata::is_marked_deleted, log_rcv::length, file_track_item::metadata, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, PGBUF_PAGE_STATE_MSG, pgbuf_set_dirty(), log_rcv::pgptr, and file_track_item::type.
int file_rv_tracker_unregister_undo | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 9891 of file file_manager.c.
References assert, log_rcv::data, ER_FAILED, file_tracker_register_internal(), log_rcv::length, log_sysop_abort(), log_sysop_end_logical_compensate(), log_sysop_start(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, and log_rcv::reference_lsa.
int file_rv_user_page_mark_delete | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 8144 of file file_manager.c.
References assert, DONT_FREE, file_log, FILE_USER_PAGE_IS_MARKED_DELETED, FILE_USER_PAGE_MARK_DELETED, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, and VPID_AS_ARGS.
int file_rv_user_page_unmark_delete_logical | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 8169 of file file_manager.c.
References assert, assert_release, log_rcv::data, DONT_FREE, ER_FAILED, file_compare_vpids(), file_extdata_at(), file_extdata_search_item(), FILE_HEADER_GET_USER_PAGE_FTAB, FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_log, FILE_USER_PAGE_CLEAR_MARK_DELETED, FILE_USER_PAGE_IS_MARKED_DELETED, vfid::fileid, log_rcv::length, log_append_compensate(), LOG_DATA_ADDR_INITIALIZER, LOG_FIND_CURRENT_TDES(), NO_ERROR, NULL, log_data_addr::offset, OLD_PAGE, vpid::pageid, pgbuf_fix, pgbuf_get_lsa(), pgbuf_get_vpid_ptr(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, log_data_addr::pgptr, RVFL_USER_PAGE_MARK_DELETE_COMPENSATE, VFID_AS_ARGS, vpid::volid, vfid::volid, VPID_AS_ARGS, and VPID_EQ.
int file_rv_user_page_unmark_delete_physical | ( | THREAD_ENTRY * | thread_p, |
LOG_RCV * | rcv | ||
) |
Definition at line 8282 of file file_manager.c.
References assert, DONT_FREE, file_log, FILE_USER_PAGE_CLEAR_MARK_DELETED, FILE_USER_PAGE_IS_MARKED_DELETED, NO_ERROR, NULL, log_rcv::offset, PGBUF_PAGE_STATE_ARGS, pgbuf_set_dirty(), log_rcv::pgptr, and VPID_AS_ARGS.
|
static |
Definition at line 3983 of file file_manager.c.
References ASSERT_ERROR_AND_SET, DISK_SECTOR_NPAGES, FILE_PARTIAL_SECTOR_INITIALIZER, file_partsect_is_bit_set(), NO_ERROR, NULL, OLD_PAGE, PAGE_FTAB, vpid::pageid, pgbuf_dealloc_page(), pgbuf_fix, pgbuf_get_page_ptype(), PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, vsid::sectid, SECTOR_FIRST_PAGEID, vpid::volid, vsid::volid, and file_partial_sector::vsid.
Referenced by file_destroy().
|
static |
Definition at line 7062 of file file_manager.c.
References file_map_context::args, assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, FILE_ALLOC_BITMAP_NBITS, FILE_PARTIAL_SECTOR_INITIALIZER, file_partsect_is_bit_set(), file_table_collector_has_page(), file_map_context::ftab_collector, file_map_context::func, file_map_context::is_partial, file_map_context::latch_cond, file_map_context::latch_mode, NO_ERROR, NULL, OLD_PAGE, PAGE_FTAB, vpid::pageid, PGBUF_CONDITIONAL_LATCH, pgbuf_fix, pgbuf_get_page_ptype(), PGBUF_LATCH_READ, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, vsid::sectid, SECTOR_FIRST_PAGEID, file_map_context::stop, vpid::volid, vsid::volid, and file_partial_sector::vsid.
Referenced by file_apply_tde_algorithm(), and file_map_pages().
|
static |
Definition at line 5675 of file file_manager.c.
References ARG_FILE_LINE, ASSERT_ERROR_AND_SET, ER_ERROR_SEVERITY, er_set(), ER_TDE_CIPHER_IS_NOT_LOADED, FILE_GET_HEADER_VPID, file_get_tde_algorithm_internal(), file_header_sanity_check(), FILE_IS_TEMPORARY, file_set_tde_algorithm_internal(), tde_cipher::is_loaded, log_append_undoredo_data2(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, pgbuf_set_dirty_and_free, PGBUF_UNCONDITIONAL_LATCH, RVFL_FHEAD_SET_TDE_ALGORITHM, TDE_ALGORITHM_NONE, and tde_Cipher.
Referenced by file_apply_tde_algorithm().
|
static |
Definition at line 5747 of file file_manager.c.
References ARG_FILE_LINE, er_log_debug, FILE_FLAG_ENCRYPTED_AES, FILE_FLAG_ENCRYPTED_ARIA, FILE_FLAG_ENCRYPTED_MASK, file_header::file_flags, file_header::self, TDE_ALGORITHM_AES, TDE_ALGORITHM_ARIA, TDE_ALGORITHM_NONE, tde_get_algorithm_name(), and VFID_AS_ARGS.
Referenced by file_rv_set_tde_algorithm(), and file_set_tde_algorithm().
int file_spacedb | ( | THREAD_ENTRY * | thread_p, |
SPACEDB_FILES * | spacedb | ||
) |
Definition at line 7653 of file file_manager.c.
References ASSERT_ERROR, file_tracker_spacedb(), i, spacedb_files::nfile, NO_ERROR, spacedb_files::npage_ftab, spacedb_files::npage_reserved, spacedb_files::npage_user, SPACEDB_FILE_COUNT, file_tempcache::spacedb_temp, SPACEDB_TEMP_FILE, and SPACEDB_TOTAL_FILE.
Referenced by netcl_spacedb(), and netsr_spacedb().
|
static |
Definition at line 4877 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, disk_compare_vsids(), ER_FAILED, FILE_ALLOC_TABLE_PAGE_FULL_SECTOR, FILE_EXTDATA_AS_ARGS, file_extdata_find_not_full(), file_extdata_find_ordered(), file_extdata_insert_at(), FILE_EXTDATA_MSG, FILE_HEADER_GET_FULL_FTAB, FILE_IS_TEMPORARY, file_log, file_log_extdata_add(), file_perm_alloc(), log_check_system_op_is_started(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, pgbuf_get_lsa(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, file_header::self, VFID_AS_ARGS, VPID_INITIALIZER, VPID_ISNULL, and VSID_AS_ARGS.
Referenced by file_perm_alloc().
|
static |
Definition at line 4827 of file file_manager.c.
References ASSERT_ERROR_AND_SET, DB_PAGESIZE, file_extdata_init(), file_extdata_size(), FILE_HEADER_GET_FULL_FTAB, file_log, file_log_extdata_set_next(), NEW_PAGE, NO_ERROR, NULL, PAGE_FTAB, pgbuf_fix, PGBUF_LATCH_WRITE, pgbuf_log_new_page(), pgbuf_set_page_ptype(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, VPID_COPY, and file_extensible_data::vpid_next.
Referenced by file_perm_alloc(), and file_table_move_partial_sectors_to_header().
|
static |
Definition at line 7279 of file file_manager.c.
References assert, ASSERT_ERROR, db_private_free, disk_check_sectors_are_reserved(), DISK_ERROR, DISK_INVALID, DISK_VALID, ER_FAILED, file_extdata_apply_funcs(), FILE_GET_HEADER_VPID, FILE_HEADER_GET_USER_PAGE_FTAB, file_header_sanity_check(), FILE_IS_NUMERABLE, file_table_check_page_is_in_sectors(), file_table_collect_all_vsids(), file_vsid_collector::n_vsids, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, and file_vsid_collector::vsids.
Referenced by file_tracker_check().
|
static |
Definition at line 8313 of file file_manager.c.
References assert_release, disk_compare_vsids(), ER_FAILED, FILE_USER_PAGE_CLEAR_MARK_DELETED, file_vsid_collector::n_vsids, NO_ERROR, NULL, VSID_FROM_VPID, and file_vsid_collector::vsids.
Referenced by file_table_check().
STATIC_INLINE int file_table_collect_all_vsids | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page_fhead, | ||
FILE_VSID_COLLECTOR * | collector_out | ||
) |
Definition at line 3918 of file file_manager.c.
References ARG_FILE_LINE, ASSERT_ERROR, assert_release, db_private_alloc, db_private_free_and_init, disk_compare_vsids(), ER_ERROR_SEVERITY, ER_FAILED, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), file_extdata_apply_funcs(), FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_table_collect_vsid(), file_header::n_sector_total, file_vsid_collector::n_vsids, NO_ERROR, NULL, and file_vsid_collector::vsids.
Referenced by file_destroy(), file_header_sanity_check(), and file_table_check().
STATIC_INLINE int file_table_collect_ftab_pages | ( | THREAD_ENTRY * | thread_p, |
PAGE_PTR | page_fhead, | ||
bool | collect_numerable, | ||
FILE_FTAB_COLLECTOR * | collector_out | ||
) |
Definition at line 6895 of file file_manager.c.
References ARG_FILE_LINE, ASSERT_ERROR, db_private_alloc, db_private_free_and_init, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), FILE_EMPTY_PAGE_BITMAP, file_extdata_apply_funcs(), file_extdata_collect_ftab_pages(), FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_HEADER_GET_USER_PAGE_FTAB, FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_log, FILE_PARTSECT_AS_ARGS, FILE_PARTSECT_MSG, file_partsect_pageid_to_offset(), file_partsect_set_bit(), file_header::n_page_ftab, NO_ERROR, file_ftab_collector::npages, file_ftab_collector::nsects, NULL, file_partial_sector::page_bitmap, vpid::pageid, file_ftab_collector::partsect_ftab, pgbuf_get_vpid(), VPID_AS_ARGS, file_partial_sector::vsid, and VSID_FROM_VPID.
Referenced by file_apply_tde_algorithm(), file_map_pages(), and file_temp_reset_user_pages().
|
static |
Definition at line 3899 of file file_manager.c.
References file_vsid_collector::n_vsids, NO_ERROR, STATIC_INLINE, and file_vsid_collector::vsids.
Referenced by file_table_collect_all_vsids().
STATIC_INLINE bool file_table_collector_has_page | ( | FILE_FTAB_COLLECTOR * | collector, |
VPID * | vpid | ||
) |
Definition at line 7031 of file file_manager.c.
References file_partsect_is_bit_set(), file_partsect_pageid_to_offset(), file_ftab_collector::nsects, vpid::pageid, file_ftab_collector::partsect_ftab, file_partial_sector::vsid, VSID_EQ, and VSID_FROM_VPID.
Referenced by file_sector_map_pages().
STATIC_INLINE int file_table_dump | ( | THREAD_ENTRY * | thread_p, |
const FILE_HEADER * | fhead, | ||
FILE * | fp | ||
) |
Definition at line 7427 of file file_manager.c.
References ASSERT_ERROR, file_extdata_apply_funcs(), file_full_table_extdata_dump(), file_full_table_item_dump(), FILE_HEADER_GET_FULL_FTAB, FILE_HEADER_GET_PART_FTAB, FILE_HEADER_GET_USER_PAGE_FTAB, FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_partial_table_extdata_dump(), file_partial_table_item_dump(), NO_ERROR, and NULL.
Referenced by file_dump().
|
static |
Definition at line 4623 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, ER_FAILED, FILE_ALLOC_TABLE_PAGE_FULL_SECTOR, FILE_ALLOC_USER_PAGE, file_extdata_append_array(), FILE_EXTDATA_AS_ARGS, file_extdata_is_empty(), file_extdata_item_count(), FILE_EXTDATA_MSG, file_extdata_remaining_capacity(), file_extdata_remove_at(), file_extdata_start(), FILE_HEADER_GET_PART_FTAB, FILE_IS_TEMPORARY, file_log, file_log_extdata_add(), file_log_extdata_remove(), file_log_extdata_set_next(), file_table_append_full_sector_page(), log_append_undoredo_data2(), file_header::n_page_ftab, file_header::n_page_user, file_header::n_sector_partial, NO_ERROR, NULL, NULL_OFFSET, OLD_PAGE, pgbuf_dealloc_page(), pgbuf_fix, pgbuf_get_lsa(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, RVFL_FHEAD_CONVERT_FTAB_TO_USER, file_header::self, VFID_AS_ARGS, VPID_AS_ARGS, VPID_COPY, VPID_ISNULL, file_extensible_data::vpid_next, and VPID_SET_NULL.
Referenced by file_perm_alloc().
|
static |
Definition at line 8413 of file file_manager.c.
References assert, assert_release, DB_PAGESIZE, DB_TEMPORARY_DATA_PURPOSE, disk_reserve_sectors(), DISK_SECTOR_NPAGES, DONT_FREE, ER_FAILED, FILE_ALLOC_TYPE_STRING, FILE_ALLOC_USER_PAGE, FILE_EMPTY_PAGE_BITMAP, file_extdata_append(), FILE_EXTDATA_AS_ARGS, file_extdata_at(), file_extdata_init(), file_extdata_is_full(), file_extdata_item_count(), FILE_EXTDATA_MSG, FILE_GET_HEADER_VPID, FILE_HEAD_ALLOC_AS_ARGS, FILE_HEAD_ALLOC_MSG, FILE_HEAD_FULL_AS_ARGS, FILE_HEAD_FULL_MSG, file_header_alloc(), FILE_HEADER_GET_PART_FTAB, file_header_sanity_check(), FILE_IS_TEMPORARY, file_log, FILE_PARTIAL_SECTOR_INITIALIZER, file_partsect_alloc(), FILE_PARTSECT_AS_ARGS, file_partsect_is_empty(), file_partsect_is_full(), FILE_PARTSECT_MSG, file_partsect_set_bit(), logtb_set_check_interrupt(), file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_total, file_header::n_sector_empty, file_header::n_sector_partial, file_header::n_sector_total, NEW_PAGE, NO_ERROR, spacedb_files::npage_ftab, spacedb_files::npage_reserved, spacedb_files::npage_user, NULL, file_header::offset_to_last_temp_alloc, OLD_PAGE, file_partial_sector::page_bitmap, PAGE_FTAB, vpid::pageid, pgbuf_fix, PGBUF_LATCH_WRITE, pgbuf_set_dirty(), pgbuf_set_dirty_and_free, pgbuf_set_page_ptype(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, vsid::sectid, SECTOR_FIRST_PAGEID, file_header::self, file_tempcache::spacedb_temp, STATIC_INLINE, vpid::volid, vsid::volid, file_header::volid_last_expand, VPID_AS_ARGS, VPID_COPY, VPID_EQ, VPID_ISNULL, file_header::vpid_last_temp_alloc, file_extensible_data::vpid_next, file_partial_sector::vsid, and VSID_AS_ARGS.
Referenced by file_alloc(), and file_numerable_add_page().
void file_temp_preserve | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid | ||
) |
Definition at line 8881 of file file_manager.c.
References assert, assert_release, file_tempcache_pop_tran_file(), file_tempcache_retire_entry(), NULL, and VFID_ISNULL.
Referenced by qmgr_create_result_file(), and session_preserve_temporary_files().
|
static |
Definition at line 8699 of file file_manager.c.
References assert, ASSERT_ERROR_AND_SET, assert_release, db_private_free, disk_compare_vsids(), DONT_FREE, ER_FAILED, FILE_EMPTY_PAGE_BITMAP, file_extdata_end(), file_extdata_start(), FILE_FTAB_COLLECTOR_INITIALIZER, FILE_FULL_PAGE_BITMAP, FILE_GET_HEADER_VPID, FILE_HEAD_FULL_AS_ARGS, FILE_HEAD_FULL_MSG, FILE_HEADER_GET_PART_FTAB, FILE_HEADER_GET_USER_PAGE_FTAB, file_header_sanity_check(), FILE_IS_NUMERABLE, FILE_IS_TEMPORARY, file_log, file_table_collect_ftab_pages(), file_header::first_index_find_nth_last, logtb_set_check_interrupt(), file_extensible_data::n_items, file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_total, file_header::n_page_user, file_header::n_sector_empty, file_header::n_sector_full, file_header::n_sector_partial, file_header::n_sector_total, NO_ERROR, spacedb_files::npage_ftab, spacedb_files::npage_reserved, spacedb_files::npage_user, file_ftab_collector::npages, file_ftab_collector::nsects, NULL, file_header::offset_to_last_temp_alloc, OLD_PAGE, file_partial_sector::page_bitmap, file_ftab_collector::partsect_ftab, pgbuf_fix, PGBUF_LATCH_WRITE, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_tempcache::spacedb_temp, file_header::vpid_find_nth_last, VPID_ISNULL, file_header::vpid_last_temp_alloc, file_header::vpid_last_user_page_ftab, file_extensible_data::vpid_next, VPID_SET_NULL, and file_partial_sector::vsid.
Referenced by file_tempcache_put().
int file_temp_retire | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid | ||
) |
Definition at line 4299 of file file_manager.c.
References file_temp_retire_internal().
Referenced by qfile_destroy_list(), qmgr_create_result_file(), qmgr_free_list_temp_file(), qmgr_free_temp_file_list(), qmgr_get_new_page(), sort_add_new_file(), sort_checkalloc_numpages_of_outfiles(), sort_inphase_sort(), and sort_return_used_resources().
STATIC_INLINE int file_temp_retire_internal | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid, | ||
bool | was_preserved | ||
) |
Definition at line 4327 of file file_manager.c.
References assert, assert_release, file_destroy(), file_tempcache_alloc_entry(), file_tempcache_lock(), file_tempcache_pop_tran_file(), file_tempcache_put(), file_tempcache_retire_entry(), file_tempcache_unlock(), NO_ERROR, NULL, and file_tempcache_entry::vfid.
Referenced by file_temp_retire(), and file_temp_retire_preserved().
int file_temp_retire_preserved | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid | ||
) |
Definition at line 4312 of file file_manager.c.
References file_temp_retire_internal(), and STATIC_INLINE.
Referenced by qfile_delete_list_cache_entry(), qmgr_free_list_temp_file(), and qmgr_free_temp_file_list().
STATIC_INLINE int file_temp_set_type | ( | THREAD_ENTRY * | thread_p, |
VFID * | vfid, | ||
FILE_TYPE | ftype | ||
) |
Definition at line 8658 of file file_manager.c.
References ASSERT_ERROR_AND_SET, assert_release, DONT_FREE, ER_FAILED, FILE_GET_HEADER_VPID, file_header_sanity_check(), FILE_IS_TEMPORARY, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, and file_header::type.
Referenced by file_tempcache_get().
STATIC_INLINE int file_tempcache_alloc_entry | ( | FILE_TEMPCACHE_ENTRY ** | entry | ) |
Definition at line 9043 of file file_manager.c.
References ARG_FILE_LINE, assert, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), file_tempcache_check_lock(), FILE_UNKNOWN_TYPE, file_tempcache::free_entries, file_tempcache_entry::next, file_tempcache::nfree_entries, NO_ERROR, NULL, STATIC_INLINE, and VFID_SET_NULL.
Referenced by file_temp_retire_internal(), and file_tempcache_get().
STATIC_INLINE void file_tempcache_cache_or_drop_entries | ( | THREAD_ENTRY * | thread_p, |
FILE_TEMPCACHE_ENTRY ** | entries | ||
) |
Definition at line 9400 of file file_manager.c.
References assert_release, file_destroy(), file_log, FILE_TEMPCACHE_ENTRY_AS_ARGS, FILE_TEMPCACHE_ENTRY_MSG, file_tempcache_put(), file_tempcache_retire_entry(), file_tempcache_entry::next, NO_ERROR, NULL, STATIC_INLINE, and file_tempcache_entry::vfid.
Referenced by file_tempcache_drop_tran_temp_files().
|
static |
Definition at line 9236 of file file_manager.c.
References assert, file_tempcache::cached_not_numerable, file_tempcache::cached_numerable, file_tempcache_entry::next, NULL, p, STATIC_INLINE, file_tempcache_entry::vfid, VFID_EQ, and VFID_ISNULL.
Referenced by file_tempcache_put().
STATIC_INLINE void file_tempcache_check_lock | ( | void | ) |
Definition at line 9135 of file file_manager.c.
References assert, file_tempcache::owner_mutex, STATIC_INLINE, and thread_get_current_entry_index().
Referenced by file_tempcache_alloc_entry(), and file_tempcache_free_entry_list().
void file_tempcache_drop_tran_temp_files | ( | THREAD_ENTRY * | thread_p | ) |
Definition at line 9381 of file file_manager.c.
References file_get_tempcache_entry_index(), file_get_tran_num_temp_files(), file_log, file_tempcache_cache_or_drop_entries(), NULL, STATIC_INLINE, and file_tempcache::tran_files.
Referenced by log_abort_local(), and log_commit_local().
STATIC_INLINE void file_tempcache_dump | ( | FILE * | fp | ) |
Definition at line 9514 of file file_manager.c.
References file_tempcache::cached_not_numerable, file_tempcache::cached_numerable, file_tempcache_lock(), file_tempcache_unlock(), file_type_to_string(), file_tempcache_entry::ftype, file_tempcache::ncached_max, file_tempcache::ncached_not_numerable, file_tempcache::ncached_numerable, file_tempcache_entry::next, NULL, file_tempcache_entry::vfid, and VFID_AS_ARGS.
|
static |
Definition at line 8972 of file file_manager.c.
References file_tempcache::cached_not_numerable, file_tempcache::cached_numerable, file_tempcache_free_entry_list(), file_tempcache_lock(), file_tempcache_unlock(), free_and_init, file_tempcache::free_entries, logtb_get_number_of_total_tran_indices(), file_tempcache::mutex, NULL, pthread_mutex_destroy, STATIC_INLINE, and file_tempcache::tran_files.
Referenced by file_manager_final().
STATIC_INLINE void file_tempcache_free_entry_list | ( | FILE_TEMPCACHE_ENTRY ** | list | ) |
Definition at line 9021 of file file_manager.c.
References file_tempcache_check_lock(), file_tempcache_entry::next, NULL, and STATIC_INLINE.
Referenced by file_tempcache_final().
STATIC_INLINE int file_tempcache_get | ( | THREAD_ENTRY * | thread_p, |
FILE_TYPE | ftype, | ||
bool | numerable, | ||
FILE_TEMPCACHE_ENTRY ** | entry | ||
) |
Definition at line 9150 of file file_manager.c.
References assert, ASSERT_ERROR, file_tempcache::cached_not_numerable, file_tempcache::cached_numerable, file_log, file_temp_set_type(), file_tempcache_alloc_entry(), FILE_TEMPCACHE_AS_ARGS, FILE_TEMPCACHE_ENTRY_AS_ARGS, FILE_TEMPCACHE_ENTRY_MSG, file_tempcache_lock(), FILE_TEMPCACHE_MSG, file_tempcache_unlock(), file_tempcache::ncached_not_numerable, file_tempcache::ncached_numerable, file_tempcache_entry::next, NO_ERROR, NULL, and VFID_SET_NULL.
Referenced by file_create_temp_internal().
|
static |
Definition at line 8909 of file file_manager.c.
References ARG_FILE_LINE, assert, file_tempcache::cached_not_numerable, file_tempcache::cached_numerable, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), free_and_init, file_tempcache::free_entries, logtb_get_number_of_total_tran_indices(), file_tempcache::mutex, file_tempcache::ncached_max, file_tempcache::ncached_not_numerable, file_tempcache::ncached_numerable, file_tempcache::nfree_entries, file_tempcache::nfree_entries_max, NO_ERROR, NULL, file_tempcache::owner_mutex, prm_get_integer_value(), PRM_ID_MAX_ENTRIES_IN_TEMP_FILE_CACHE, pthread_mutex_destroy, pthread_mutex_init, file_tempcache::spacedb_temp, and file_tempcache::tran_files.
STATIC_INLINE void file_tempcache_lock | ( | void | ) |
Definition at line 778 of file file_manager.c.
Referenced by file_temp_retire_internal(), file_tempcache_dump(), file_tempcache_final(), file_tempcache_get(), file_tempcache_put(), and file_tempcache_retire_entry().
STATIC_INLINE FILE_TEMPCACHE_ENTRY* file_tempcache_pop_tran_file | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid | ||
) |
Definition at line 9435 of file file_manager.c.
References assert_release, file_get_tempcache_entry_index(), file_log, FILE_TEMPCACHE_ENTRY_AS_ARGS, FILE_TEMPCACHE_ENTRY_MSG, file_tempcache_entry::next, NULL, STATIC_INLINE, file_tempcache::tran_files, file_tempcache_entry::vfid, and VFID_EQ.
Referenced by file_temp_preserve(), and file_temp_retire_internal().
STATIC_INLINE void file_tempcache_push_tran_file | ( | THREAD_ENTRY * | thread_p, |
FILE_TEMPCACHE_ENTRY * | entry | ||
) |
Definition at line 9476 of file file_manager.c.
References file_get_tempcache_entry_index(), file_log, FILE_TEMPCACHE_ENTRY_AS_ARGS, FILE_TEMPCACHE_ENTRY_MSG, file_tempcache_entry::next, and file_tempcache::tran_files.
Referenced by file_create_temp_internal().
STATIC_INLINE bool file_tempcache_put | ( | THREAD_ENTRY * | thread_p, |
FILE_TEMPCACHE_ENTRY * | entry | ||
) |
Definition at line 9277 of file file_manager.c.
References assert, ASSERT_ERROR, file_tempcache::cached_not_numerable, file_tempcache::cached_numerable, file_header_copy(), FILE_IS_NUMERABLE, file_log, file_temp_reset_user_pages(), FILE_TEMPCACHE_AS_ARGS, file_tempcache_check_duplicate(), FILE_TEMPCACHE_ENTRY_AS_ARGS, FILE_TEMPCACHE_ENTRY_MSG, file_tempcache_lock(), FILE_TEMPCACHE_MSG, file_tempcache_unlock(), file_tempcache_entry::ftype, file_header::n_page_user, file_tempcache::ncached_not_numerable, file_tempcache::ncached_numerable, file_tempcache_entry::next, file_tempcache::nfree_entries_max, NO_ERROR, NULL, prm_get_integer_value(), PRM_ID_MAX_PAGES_IN_TEMP_FILE_CACHE, STATIC_INLINE, file_header::type, file_tempcache_entry::vfid, and VFID_ISNULL.
Referenced by file_temp_retire_internal(), and file_tempcache_cache_or_drop_entries().
STATIC_INLINE void file_tempcache_retire_entry | ( | FILE_TEMPCACHE_ENTRY * | entry | ) |
Definition at line 9079 of file file_manager.c.
References assert, file_tempcache_lock(), file_tempcache_unlock(), file_tempcache::free_entries, file_tempcache::mutex, file_tempcache_entry::next, file_tempcache::nfree_entries, file_tempcache::nfree_entries_max, file_tempcache::owner_mutex, pthread_mutex_lock, STATIC_INLINE, and thread_get_current_entry_index().
Referenced by file_create_temp_internal(), file_temp_preserve(), file_temp_retire_internal(), and file_tempcache_cache_or_drop_entries().
STATIC_INLINE void file_tempcache_unlock | ( | void | ) |
Definition at line 9120 of file file_manager.c.
References assert, file_tempcache::mutex, file_tempcache::owner_mutex, pthread_mutex_unlock, STATIC_INLINE, and thread_get_current_entry_index().
Referenced by file_temp_retire_internal(), file_tempcache_dump(), file_tempcache_final(), file_tempcache_get(), file_tempcache_put(), and file_tempcache_retire_entry().
|
static |
Definition at line 9938 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, ER_FAILED, file_compare_track_items(), file_extdata_search_item(), file_track_item::fileid, vfid::fileid, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_track_item::volid, and vfid::volid.
Referenced by file_rv_tracker_mark_heap_deleted().
DISK_ISVALID file_tracker_check | ( | THREAD_ENTRY * | thread_p | ) |
Definition at line 11134 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, DISK_ERROR, DISK_INVALID, DISK_VALID, ER_FAILED, file_extdata_at(), file_table_check(), file_tracker_interruptable_iterate(), file_tracker_map(), FILE_UNKNOWN_TYPE, file_track_item::fileid, vfid::fileid, lock_unlock_object(), NO_ERROR, NULL, OID_INITIALIZER, OID_ISNULL, oid_Root_class_oid, PGBUF_LATCH_READ, SCH_S_LOCK, VFID_INITIALIZER, VFID_ISNULL, file_track_item::volid, and vfid::volid.
Referenced by xboot_check_db_consistency().
int file_tracker_create | ( | THREAD_ENTRY * | thread_p, |
VFID * | vfid_tracker_out | ||
) |
Definition at line 9564 of file file_manager.c.
References assert, ASSERT_ERROR, file_alloc_sticky_first_page(), file_create_with_npages(), FILE_TRACKER, file_tracker_init_page(), log_sysop_abort(), log_sysop_commit(), log_sysop_start(), NO_ERROR, NULL, VFID_COPY, VFID_SET_NULL, and VPID_SET_NULL.
Referenced by boot_create_all_volumes().
int file_tracker_dump | ( | THREAD_ENTRY * | thread_p, |
FILE * | fp | ||
) |
Definition at line 10868 of file file_manager.c.
References file_tracker_item_dump(), file_tracker_map(), and PGBUF_LATCH_READ.
Referenced by diagdb().
int file_tracker_dump_all_btree_capacities | ( | THREAD_ENTRY * | thread_p, |
FILE * | fp | ||
) |
Definition at line 11121 of file file_manager.c.
References file_tracker_item_dump_btree_capacity(), file_tracker_map(), and PGBUF_LATCH_READ.
Referenced by diagdb().
int file_tracker_dump_all_capacities | ( | THREAD_ENTRY * | thread_p, |
FILE * | fp | ||
) |
Definition at line 10929 of file file_manager.c.
References ASSERT_ERROR, file_tracker_item_dump_capacity(), file_tracker_map(), NO_ERROR, and PGBUF_LATCH_READ.
Referenced by diagdb().
int file_tracker_dump_all_heap | ( | THREAD_ENTRY * | thread_p, |
FILE * | fp, | ||
bool | dump_records | ||
) |
Definition at line 10994 of file file_manager.c.
References file_tracker_dump_heap_context::dump_records, file_tracker_item_dump_heap(), file_tracker_map(), file_tracker_dump_heap_context::fp, and PGBUF_LATCH_READ.
Referenced by diagdb().
int file_tracker_dump_all_heap_capacities | ( | THREAD_ENTRY * | thread_p, |
FILE * | fp | ||
) |
Definition at line 11058 of file file_manager.c.
References DB_PAGESIZE, file_tracker_item_dump_heap_capacity(), file_tracker_map(), IO_PAGESIZE, and PGBUF_LATCH_READ.
Referenced by diagdb().
STATIC_INLINE int file_tracker_get_and_protect | ( | THREAD_ENTRY * | thread_p, |
FILE_TYPE | desired_type, | ||
FILE_TRACK_ITEM * | item, | ||
OID * | class_oid, | ||
bool * | stop | ||
) |
Definition at line 10559 of file file_manager.c.
References ARG_FILE_LINE, assert, ASSERT_ERROR_AND_SET, file_descriptors::btree, file_descriptors::btree_key_overflow, file_heap_des::class_oid, file_ovf_heap_des::class_oid, file_btree_des::class_oid, file_ovf_btree_des::class_oid, file_header::descriptor, ER_CANNOT_CHECK_FILE, ER_NOTIFICATION_SEVERITY, er_set(), FILE_BTREE, FILE_BTREE_OVERFLOW_KEY, FILE_GET_TRACKER_LOCK_MODE, file_header_sanity_check(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, FILE_MULTIPAGE_OBJECT_HEAP, FILE_UNKNOWN_TYPE, file_track_item::fileid, file_descriptors::heap, file_track_metadata::heap, file_descriptors::heap_overflow, file_track_heap_metadata::is_marked_deleted, LK_COND_LOCK, LK_GRANTED, lock_object(), file_track_item::metadata, NO_ERROR, NULL, OID_AS_ARGS, OID_ISNULL, oid_Root_class_oid, OID_SET_NULL, OLD_PAGE, vpid::pageid, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_track_item::type, file_track_item::volid, and vpid::volid.
Referenced by file_tracker_interruptable_iterate().
|
static |
Definition at line 9640 of file file_manager.c.
References DB_PAGESIZE, DONT_FREE, file_extdata_init(), log_append_undoredo_data2(), NO_ERROR, NULL, PAGE_FTAB, pgbuf_set_dirty(), pgbuf_set_page_ptype(), and RVPGBUF_NEW_PAGE.
Referenced by file_tracker_create(), and file_tracker_register_internal().
int file_tracker_interruptable_iterate | ( | THREAD_ENTRY * | thread_p, |
FILE_TYPE | desired_ftype, | ||
VFID * | vfid, | ||
OID * | class_oid | ||
) |
Definition at line 10695 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, ER_FAILED, file_compare_track_items(), file_extdata_at(), file_extdata_item_count(), file_extdata_search_item(), FILE_GET_TRACKER_LOCK_MODE, file_tracker_get_and_protect(), file_track_item::fileid, vfid::fileid, lock_unlock_object(), NO_ERROR, NULL, OID_ISNULL, oid_Root_class_oid, OID_SET_NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, VFID_EQ, VFID_ISNULL, VFID_SET_NULL, file_track_item::volid, vfid::volid, VPID_ISNULL, and file_extensible_data::vpid_next.
Referenced by btree_check_all(), btree_repair_prev_link(), file_tracker_check(), and heap_check_all_heaps().
|
static |
Definition at line 10838 of file file_manager.c.
References ASSERT_ERROR, file_dump(), file_extdata_at(), file_track_item::fileid, vfid::fileid, NO_ERROR, file_track_item::volid, and vfid::volid.
Referenced by file_tracker_dump().
|
static |
Definition at line 11077 of file file_manager.c.
References ASSERT_ERROR, btree_dump_capacity(), btree_get_btid_from_file(), FILE_BTREE, file_extdata_at(), file_track_item::fileid, vfid::fileid, NO_ERROR, file_track_item::type, btid::vfid, file_track_item::volid, and vfid::volid.
Referenced by file_tracker_dump_all_btree_capacities().
|
static |
Definition at line 10886 of file file_manager.c.
References ASSERT_ERROR_AND_SET, file_extdata_at(), file_header_dump_descriptor(), file_header_sanity_check(), FILE_HEAP, file_type_to_string(), file_track_item::fileid, file_track_metadata::heap, file_track_heap_metadata::is_marked_deleted, file_track_item::metadata, file_header::n_page_user, NO_ERROR, NULL, OLD_PAGE, vpid::pageid, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_header::type, file_track_item::type, file_track_item::volid, and vpid::volid.
Referenced by file_tracker_dump_all_capacities().
|
static |
Definition at line 10956 of file file_manager.c.
References ASSERT_ERROR, file_tracker_dump_heap_context::dump_records, file_extdata_at(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, file_track_item::fileid, vfid::fileid, file_tracker_dump_heap_context::fp, heap_dump(), heap_get_hfid_from_vfid(), NO_ERROR, file_track_item::type, hfid::vfid, file_track_item::volid, and vfid::volid.
Referenced by file_tracker_dump_all_heap().
|
static |
Definition at line 11016 of file file_manager.c.
References ASSERT_ERROR, file_extdata_at(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, file_track_item::fileid, vfid::fileid, heap_dump_capacity(), heap_get_hfid_from_vfid(), NO_ERROR, file_track_item::type, hfid::vfid, file_track_item::volid, and vfid::volid.
Referenced by file_tracker_dump_all_heap_capacities().
|
static |
Definition at line 10278 of file file_manager.c.
References assert, DONT_FREE, file_extdata_at(), FILE_HEAP, file_log, file_track_item::fileid, file_track_metadata::heap, file_track_heap_metadata::is_marked_deleted, file_track_mark_heap_deleted_context::is_undo, log_append_compensate_with_undo_nxlsa(), log_append_run_postpone(), LOG_DATA_ADDR_INITIALIZER, LOG_FIND_CURRENT_TDES(), LSA_AS_ARGS, file_track_item::metadata, NO_ERROR, NULL, log_data_addr::offset, pgbuf_get_lsa(), pgbuf_get_vpid_ptr(), PGBUF_PAGE_MODIFY_ARGS, PGBUF_PAGE_MODIFY_MSG, pgbuf_set_dirty(), log_data_addr::pgptr, file_track_mark_heap_deleted_context::ref_lsa, RVFL_TRACKER_HEAP_MARK_DELETED, file_track_item::type, and file_track_item::volid.
Referenced by file_rv_tracker_mark_heap_deleted().
|
static |
Definition at line 10127 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, file_heap_des::class_oid, file_tracker_reuse_heap_context::class_oid, file_header::descriptor, DONT_FREE, file_extdata_at(), FILE_GET_HEADER_VPID, file_get_sticky_first_page(), file_header_sanity_check(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, file_log, file_track_item::fileid, vfid::fileid, file_descriptors::heap, file_track_metadata::heap, file_heap_des::hfid, file_tracker_reuse_heap_context::hfid_out, hfid::hpgid, file_track_heap_metadata::is_marked_deleted, log_append_undoredo_data2(), log_check_system_op_is_started(), logtb_get_current_mvccid(), file_track_item::metadata, NO_ERROR, NULL, OLD_PAGE, vpid::pageid, pgbuf_fix, pgbuf_get_lsa(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), pgbuf_set_dirty_and_free, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, RVFL_FILEDESC_UPD, RVFL_TRACKER_HEAP_REUSE, file_header::self, file_header::type, file_track_item::type, vacuum_is_file_dropped(), hfid::vfid, VFID_AS_ARGS, VFID_EQ, VFID_SET_NULL, file_track_item::volid, vpid::volid, vfid::volid, and VPID_INITIALIZER.
Referenced by file_tracker_reuse_heap().
|
static |
Definition at line 11300 of file file_manager.c.
References ASSERT_ERROR_AND_SET, FILE_BTREE, file_extdata_at(), FILE_HEAP, FILE_HEAP_REUSE_SLOTS, file_track_item::fileid, file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_user, spacedb_files::nfile, NO_ERROR, spacedb_files::npage_ftab, spacedb_files::npage_reserved, spacedb_files::npage_user, NULL, OLD_PAGE, vpid::pageid, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, spacedb(), SPACEDB_HEAP_FILE, SPACEDB_INDEX_FILE, SPACEDB_SYSTEM_FILE, file_header::type, file_track_item::volid, and vpid::volid.
Referenced by file_tracker_spacedb().
int file_tracker_load | ( | THREAD_ENTRY * | thread_p, |
const VFID * | vfid | ||
) |
Definition at line 9613 of file file_manager.c.
References assert, ASSERT_ERROR, file_get_sticky_first_page(), NO_ERROR, NULL, and VFID_ISNULL.
Referenced by boot_restart_server(), and xboot_emergency_patch().
|
static |
Definition at line 10009 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, file_extdata_item_count(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, VPID_INITIALIZER, VPID_ISNULL, and file_extensible_data::vpid_next.
Referenced by file_tracker_check(), file_tracker_dump(), file_tracker_dump_all_btree_capacities(), file_tracker_dump_all_capacities(), file_tracker_dump_all_heap(), file_tracker_dump_all_heap_capacities(), file_tracker_reuse_heap(), and file_tracker_spacedb().
|
static |
Definition at line 9663 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, file_tracker_register_internal(), file_track_item::fileid, vfid::fileid, log_check_system_op_is_started(), file_track_item::metadata, file_track_metadata::metadata_size_tracker, NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, file_track_item::type, file_track_item::volid, vfid::volid, and VPID_ISNULL.
Referenced by file_create().
|
static |
Definition at line 9719 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, assert_release, DONT_FREE, ER_FAILED, file_alloc(), file_compare_track_items(), file_extdata_find_not_full(), file_extdata_find_ordered(), file_extdata_insert_at(), file_extdata_is_full(), file_log, file_log_extdata_add(), file_log_extdata_set_next(), FILE_TRACK_ITEM_AS_ARGS, FILE_TRACK_ITEM_MSG, file_tracker_init_page(), log_check_system_op_is_started(), NO_ERROR, NULL, OLD_PAGE, PAGE_FTAB, pgbuf_fix, pgbuf_get_lsa(), pgbuf_get_page_ptype(), PGBUF_LATCH_WRITE, PGBUF_PAGE_MODIFY_ARGS, pgbuf_set_dirty(), PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, pgbuf_unfix_and_init, and file_extensible_data::vpid_next.
Referenced by file_rv_tracker_unregister_undo(), and file_tracker_register().
int file_tracker_reuse_heap | ( | THREAD_ENTRY * | thread_p, |
const OID * | class_oid, | ||
HFID * | hfid_out | ||
) |
Definition at line 10252 of file file_manager.c.
References assert, file_tracker_reuse_heap_context::class_oid, file_tracker_item_reuse_heap(), file_tracker_map(), file_tracker_reuse_heap_context::hfid_out, HFID_SET_NULL, NULL, and PGBUF_LATCH_WRITE.
Referenced by heap_create_internal().
|
static |
Definition at line 11356 of file file_manager.c.
References ASSERT_ERROR, ASSERT_ERROR_AND_SET, FILE_GET_HEADER_VPID, file_tracker_item_spacedb(), file_tracker_map(), file_header::n_page_free, file_header::n_page_ftab, file_header::n_page_user, spacedb_files::nfile, NO_ERROR, spacedb_files::npage_ftab, spacedb_files::npage_reserved, spacedb_files::npage_user, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_READ, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, and SPACEDB_SYSTEM_FILE.
Referenced by file_spacedb().
|
static |
Definition at line 9816 of file file_manager.c.
References assert, ASSERT_ERROR, ASSERT_ERROR_AND_SET, file_compare_track_items(), file_dealloc(), file_extdata_find_and_remove_item(), file_log, FILE_TRACKER, file_track_item::fileid, vfid::fileid, log_check_system_op_is_started(), log_sysop_abort(), log_sysop_end_logical_undo(), log_sysop_start(), NO_ERROR, NULL, OLD_PAGE, pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix, RVFL_TRACKER_UNREGISTER, VFID_ISNULL, file_track_item::volid, vfid::volid, VPID_AS_ARGS, VPID_INITIALIZER, and VPID_ISNULL.
Referenced by file_destroy().
Definition at line 3025 of file file_manager.c.
References FILE_BTREE, FILE_BTREE_OVERFLOW_KEY, FILE_CATALOG, FILE_DROPPED_FILES, FILE_EXTENDIBLE_HASH, FILE_EXTENDIBLE_HASH_DIRECTORY, FILE_HEAP, FILE_HEAP_REUSE_SLOTS, FILE_MULTIPAGE_OBJECT_HEAP, FILE_QUERY_AREA, FILE_TEMP, FILE_TRACKER, FILE_UNKNOWN_TYPE, and FILE_VACUUM_DATA.
Referenced by file_create(), file_dealloc(), file_tempcache_dump(), file_tracker_item_dump_capacity(), heap_cache_class_info(), heap_hfid_cache_get(), and vacuum_heap_get_hfid_and_file_type().
|
static |
Definition at line 7607 of file file_manager.c.
References FILE_EXTDATA_AS_ARGS, FILE_EXTDATA_MSG, and NO_ERROR.
|
static |
Definition at line 7627 of file file_manager.c.
References FILE_USER_PAGE_IS_MARKED_DELETED, NO_ERROR, and VPID_AS_ARGS.
int xfile_apply_tde_to_class_files | ( | THREAD_ENTRY * | thread_p, |
const OID * | class_oid | ||
) |
Definition at line 11503 of file file_manager.c.
References assert, ASSERT_ERROR_AND_SET, or_index::btid, btree_get_root_header(), ER_FAILED, file_apply_tde_algorithm(), heap_classrepr_free_and_init, heap_classrepr_get(), heap_get_class_info(), heap_get_class_tde_algorithm(), heap_ovf_find_vfid(), HFID_INITIALIZER, i, or_classrep::indexes, or_classrep::n_indexes, NO_ERROR, NULL, NULL_REPRID, OID_ISNULL, OLD_PAGE, btree_root_header::ovfid, PAGE_BTREE, vpid::pageid, pgbuf_check_page_ptype(), pgbuf_fix, PGBUF_LATCH_WRITE, PGBUF_UNCONDITIONAL_LATCH, pgbuf_unfix_and_init, btid::root_pageid, TDE_ALGORITHM_NONE, hfid::vfid, btid::vfid, VFID_ISNULL, vpid::volid, and vfid::volid.
Referenced by file_apply_tde_to_class_files(), and sfile_apply_tde_to_class_files().
|
static |
Definition at line 314 of file file_manager.c.
|
static |
Definition at line 500 of file file_manager.c.
|
static |
Definition at line 506 of file file_manager.c.
|
static |
Definition at line 507 of file file_manager.c.