Get the App
SLTechnology News&Howtos  ›  Database  › 

Interpretation of PostgreSQL Source Code-MVCC#19 (vacuum procedure-heap_execute_freeze_tuple function)

Shulou Source: shulou.com Published: 2022-06-01 05:08:38 10月04日 Update

This section briefly introduces the processing flow of manual vacuum execution by PostgreSQL, and mainly analyzes the implementation logic of the ExecVacuum- > vacuum- > vacuum_rel- > heap_vacuum_rel- > lazy_scan_heap- > heap_execute_freeze_tuple function, which performs the actual tuple freeze operation (preparation work has been completed previously).

I. data structure

Macro definition

Vacuum and Analyze command options

/ *-- * Vacuum and Analyze Statements * Vacuum and Analyze command options * * Even though these are nominally two statements, it's convenient to use * just one node type for both. Note that at least one of VACOPT_VACUUM * and VACOPT_ANALYZE must be set in options. Although there are two different statements here, you only need to use a uniform Node type. * Note that at least VACOPT_VACUUM/VACOPT_ANALYZE is set in the options. *-- * / typedef enum VacuumOption {VACOPT_VACUUM = 1

Tags: Field storage type transaction command actual structure information header space data tag process processing composition binary bitmap background properties situation Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Huawei Microsoft Shulou Information MySQL NVidia