Thanks to visit codestin.com
Credit goes to doxygen.postgresql.org

PostgreSQL Source Code git master
vacuuming.h
Go to the documentation of this file.
1/*-------------------------------------------------------------------------
2 *
3 * vacuuming.h
4 * Common declarations for vacuuming.c
5 *
6 * Portions Copyright (c) 1996-2025, PostgreSQL Global Development Group
7 * Portions Copyright (c) 1994, Regents of the University of California
8 *
9 * src/bin/scripts/vacuuming.h
10 *
11 *-------------------------------------------------------------------------
12 */
13#ifndef VACUUMING_H
14#define VACUUMING_H
15
16#include "common.h"
19
20typedef enum
21{
26
27/* For analyze-in-stages mode */
28#define ANALYZE_NO_STAGE -1
29#define ANALYZE_NUM_STAGES 3
30
31/* vacuum options controlled by user flags */
32typedef struct vacuumingOptions
33{
36 bool verbose;
38 bool full;
39 bool freeze;
44 int parallel_workers; /* >= 0 indicates user specified the
45 * parallel degree, otherwise -1 */
55
56/* Valid values for vacuumingOptions->objfilter */
57#define OBJFILTER_ALL_DBS 0x01 /* --all */
58#define OBJFILTER_DATABASE 0x02 /* --dbname */
59#define OBJFILTER_TABLE 0x04 /* --table */
60#define OBJFILTER_SCHEMA 0x08 /* --schema */
61#define OBJFILTER_SCHEMA_EXCLUDE 0x10 /* --exclude-schema */
62
63extern int vacuuming_main(ConnParams *cparams, const char *dbname,
64 const char *maintenance_db, vacuumingOptions *vacopts,
65 SimpleStringList *objects,
66 unsigned int tbl_count,
67 int concurrentCons,
68 const char *progname, bool echo, bool quiet);
69
70extern char *escape_quotes(const char *src);
71
72#endif /* VACUUMING_H */
uint32 bits32
Definition: c.h:547
const char * progname
Definition: main.c:44
char * dbname
Definition: streamutil.c:49
bool force_index_cleanup
Definition: vacuuming.h:47
RunMode mode
Definition: vacuuming.h:34
bool no_index_cleanup
Definition: vacuuming.h:46
bits32 objfilter
Definition: vacuuming.h:35
int parallel_workers
Definition: vacuuming.h:44
bool disable_page_skipping
Definition: vacuuming.h:40
bool process_toast
Definition: vacuuming.h:50
char * buffer_usage_limit
Definition: vacuuming.h:52
bool missing_stats_only
Definition: vacuuming.h:53
bool skip_database_stats
Definition: vacuuming.h:51
char * escape_quotes(const char *src)
Definition: vacuuming.c:997
RunMode
Definition: vacuuming.h:21
@ MODE_ANALYZE
Definition: vacuuming.h:23
@ MODE_VACUUM
Definition: vacuuming.h:22
@ MODE_ANALYZE_IN_STAGES
Definition: vacuuming.h:24
struct vacuumingOptions vacuumingOptions
int vacuuming_main(ConnParams *cparams, const char *dbname, const char *maintenance_db, vacuumingOptions *vacopts, SimpleStringList *objects, unsigned int tbl_count, int concurrentCons, const char *progname, bool echo, bool quiet)
Definition: vacuuming.c:54