PostgreSQL Source Code: src/bin/pg_basebackup/walmethods.h Source File (original) (raw)
1
2
3
4
5
6
7
8
9
10
11
13
16
17typedef struct
18{
22
23
24
25
26
27
28
30
31typedef enum
32{
37
38
39
40
42{
43
44
45
46
47
48
49 Walfile *(*open_for_write) (WalWriteMethod *wwmethod, const char *pathname, const char *temp_suffix, size_t pad_to_size);
50
51
52
53
54
56
57
59
60
62
63
64
65
66
67 char *(*get_file_name) (WalWriteMethod *wwmethod, const char *pathname, const char *temp_suffix);
68
69
70
71
72
74
75
76
77
79
80
81
82
83
84
85
87
88
89
90
91
94
95
96
97
98
99
100
101
102
104{
109 const char *lasterrstring;
111
112
113
114
115
116
117
118};
119
120
121
122
123
124
125
126
129 int compression_level, bool sync);
132 int compression_level, bool sync);
133
static pg_compress_algorithm compression_algorithm
void(* free)(WalWriteMethod *wwmethod)
bool(* existsfile)(WalWriteMethod *wwmethod, const char *pathname)
ssize_t(* write)(Walfile *f, const void *buf, size_t count)
ssize_t(* get_file_size)(WalWriteMethod *wwmethod, const char *pathname)
int(* close)(Walfile *f, WalCloseMethod method)
bool(* finish)(WalWriteMethod *wwmethod)
const char * lasterrstring
const WalWriteMethodOps * ops
pg_compress_algorithm compression_algorithm
WalWriteMethod * wwmethod
WalWriteMethod * CreateWalTarMethod(const char *tarbase, pg_compress_algorithm compression_algorithm, int compression_level, bool sync)
struct WalWriteMethodOps WalWriteMethodOps
WalWriteMethod * CreateWalDirectoryMethod(const char *basedir, pg_compress_algorithm compression_algorithm, int compression_level, bool sync)
const char * GetLastWalMethodError(WalWriteMethod *wwmethod)