postgresql/src/backend/access
Alvaro Herrera b060dbe000
Rework XLogReader callback system
Code review for 0dc8ead463, prompted by a bug closed by 91c40548d5.

XLogReader's system for opening and closing segments had gotten too
complicated, with callbacks being passed at both the XLogReaderAllocate
level (read_page) as well as at the WALRead level (segment_open).  This
was confusing and hard to follow, so restructure things so that these
callbacks are passed together at XLogReaderAllocate time, and add
another callback to the set (segment_close) to make it a coherent whole.
Also, ensure XLogReaderState is an argument to all the callbacks, so
that they can grab at the ->private data if necessary.

Document the whole arrangement more clearly.

Author: Álvaro Herrera <alvherre@alvh.no-ip.org>
Reviewed-by: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Discussion: https://postgr.es/m/20200422175754.GA19858@alvherre.pgsql
2020-05-08 15:40:11 -04:00
..
brin Implement operator class parameters 2020-03-30 19:17:23 +03:00
common Implement operator class parameters 2020-03-30 19:17:23 +03:00
gin Modify additional power 2 calculations to use new helper functions 2020-04-08 18:29:51 +12:00
gist Skip WAL for new relfilenodes, under wal_level=minimal. 2020-04-04 12:25:34 -07:00
hash Modify various power 2 calculations to use new helper functions 2020-04-08 16:55:03 +12:00
heap Change the display of WAL usage statistics in Explain. 2020-05-05 08:00:53 +05:30
index Remove rudiments of supporting procnum == 0 from 911e702077 2020-03-30 23:43:25 +03:00
nbtree Refactor nbtree deletion INCOMPLETE_SPLIT check. 2020-05-07 16:08:54 -07:00
rmgrdesc Harmonize nbtree page split point code. 2020-04-13 16:39:55 -07:00
spgist Fix missing SP-GiST support in 911e702077 2020-03-30 23:45:03 +03:00
table Introduce macros for typalign and typstorage constants. 2020-03-04 10:34:25 -05:00
tablesample Move src/backend/utils/hash/hashfn.c to src/common 2020-02-27 09:25:41 +05:30
transam Rework XLogReader callback system 2020-05-08 15:40:11 -04:00
Makefile Introduce access/{table.h, relation.h}, for generic functions from heapam.h. 2019-01-21 10:51:36 -08:00