Skip to content

Commit 21c09e9

Browse files
committed
Split heapam_xlog.h from heapam.h
The heapam XLog functions are used by other modules, not all of which are interested in the rest of the heapam API. With this, we let them get just the XLog stuff in which they are interested and not pollute them with unrelated includes. Also, since heapam.h no longer requires xlog.h, many files that do include heapam.h no longer get xlog.h automatically, including a few headers. This is useful because heapam.h is getting pulled in by execnodes.h, which is in turn included by a lot of files.
1 parent fda0594 commit 21c09e9

File tree

26 files changed

+287
-244
lines changed

26 files changed

+287
-244
lines changed

src/backend/access/gin/gininsert.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
#include "postgres.h"
1616

1717
#include "access/gin_private.h"
18+
#include "access/heapam_xlog.h"
1819
#include "catalog/index.h"
1920
#include "miscadmin.h"
2021
#include "storage/bufmgr.h"

src/backend/access/heap/heapam.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
#include "postgres.h"
4242

4343
#include "access/heapam.h"
44+
#include "access/heapam_xlog.h"
4445
#include "access/hio.h"
4546
#include "access/multixact.h"
4647
#include "access/relscan.h"

src/backend/access/heap/pruneheap.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
#include "postgres.h"
1616

1717
#include "access/heapam.h"
18+
#include "access/heapam_xlog.h"
1819
#include "access/transam.h"
1920
#include "miscadmin.h"
2021
#include "pgstat.h"

src/backend/access/heap/rewriteheap.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@
103103
#include "postgres.h"
104104

105105
#include "access/heapam.h"
106+
#include "access/heapam_xlog.h"
106107
#include "access/rewriteheap.h"
107108
#include "access/transam.h"
108109
#include "access/tuptoaster.h"

src/backend/access/heap/visibilitymap.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@
8282
*/
8383
#include "postgres.h"
8484

85-
#include "access/heapam.h"
85+
#include "access/heapam_xlog.h"
8686
#include "access/visibilitymap.h"
8787
#include "miscadmin.h"
8888
#include "storage/bufmgr.h"

src/backend/access/index/genam.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
#include "access/relscan.h"
2323
#include "access/transam.h"
2424
#include "catalog/index.h"
25+
#include "lib/stringinfo.h"
2526
#include "miscadmin.h"
2627
#include "storage/bufmgr.h"
2728
#include "utils/builtins.h"

src/backend/access/nbtree/nbtree.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
*/
1919
#include "postgres.h"
2020

21+
#include "access/heapam_xlog.h"
2122
#include "access/nbtree.h"
2223
#include "access/relscan.h"
2324
#include "catalog/index.h"

src/backend/access/nbtree/nbtsort.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@
6666

6767
#include "postgres.h"
6868

69+
#include "access/heapam_xlog.h"
6970
#include "access/nbtree.h"
7071
#include "miscadmin.h"
7172
#include "storage/smgr.h"

src/backend/access/nbtree/nbtxlog.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
*/
1515
#include "postgres.h"
1616

17+
#include "access/heapam_xlog.h"
1718
#include "access/nbtree.h"
1819
#include "access/transam.h"
1920
#include "storage/procarray.h"

src/backend/access/spgist/spginsert.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#include "postgres.h"
1818

1919
#include "access/genam.h"
20+
#include "access/heapam_xlog.h"
2021
#include "access/spgist_private.h"
2122
#include "catalog/index.h"
2223
#include "miscadmin.h"

0 commit comments

Comments
 (0)