PostgreSQL Source Code  git master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
bgwriter.h
Go to the documentation of this file.
1 /*-------------------------------------------------------------------------
2  *
3  * bgwriter.h
4  * Exports from postmaster/bgwriter.c and postmaster/checkpointer.c.
5  *
6  * The bgwriter process used to handle checkpointing duties too. Now
7  * there is a separate process, but we did not bother to split this header.
8  *
9  * Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group
10  *
11  * src/include/postmaster/bgwriter.h
12  *
13  *-------------------------------------------------------------------------
14  */
15 #ifndef _BGWRITER_H
16 #define _BGWRITER_H
17 
18 #include "storage/block.h"
19 #include "storage/relfilenode.h"
20 
21 
22 /* GUC options */
23 extern int BgWriterDelay;
24 extern int CheckPointTimeout;
25 extern int CheckPointWarning;
26 extern double CheckPointCompletionTarget;
27 
29 extern void CheckpointerMain(void) pg_attribute_noreturn();
30 
31 extern void RequestCheckpoint(int flags);
32 extern void CheckpointWriteDelay(int flags, double progress);
33 
34 extern bool ForwardFsyncRequest(RelFileNode rnode, ForkNumber forknum,
35  BlockNumber segno);
36 extern void AbsorbFsyncRequests(void);
37 
38 extern Size CheckpointerShmemSize(void);
39 extern void CheckpointerShmemInit(void);
40 
41 extern bool FirstCallSinceLastCheckpoint(void);
42 
43 #endif /* _BGWRITER_H */
bool FirstCallSinceLastCheckpoint(void)
void CheckpointWriteDelay(int flags, double progress)
Definition: checkpointer.c:677
int CheckPointWarning
Definition: checkpointer.c:146
int CheckPointTimeout
Definition: checkpointer.c:145
uint32 BlockNumber
Definition: block.h:31
void CheckpointerMain(void) pg_attribute_noreturn()
Definition: checkpointer.c:193
bool ForwardFsyncRequest(RelFileNode rnode, ForkNumber forknum, BlockNumber segno)
void CheckpointerShmemInit(void)
Definition: checkpointer.c:926
Size CheckpointerShmemSize(void)
Definition: checkpointer.c:907
ForkNumber
Definition: relpath.h:24
void BackgroundWriterMain(void) pg_attribute_noreturn()
Definition: bgwriter.c:110
int progress
Definition: pgbench.c:172
void RequestCheckpoint(int flags)
Definition: checkpointer.c:967
double CheckPointCompletionTarget
Definition: checkpointer.c:147
size_t Size
Definition: c.h:356
#define pg_attribute_noreturn()
Definition: c.h:653
int BgWriterDelay
Definition: bgwriter.c:67
void AbsorbFsyncRequests(void)