Teach xlogreader to follow timeline switches
Simon Riggs <simon@2ndQuadrant.com>
Teach xlogreader to follow timeline switches Uses page-based mechanism to ensure we’re using the correct timeline. Tests are included to exercise the functionality using a cold disk-level copy of the master that's started up as a replica with slots intact, but the intended use of the functionality is with later features. Craig Ringer, reviewed by Simon Riggs and Andres Freund
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/access/transam/xlogutils.c | modified | +201 −14 |
| src/backend/replication/logical/logicalfuncs.c | modified | +6 −2 |
| src/backend/replication/walsender.c | modified | +7 −4 |
| src/include/access/xlogreader.h | modified | +16 −0 |
| src/include/access/xlogutils.h | modified | +3 −0 |
| src/test/recovery/Makefile | modified | +2 −0 |
| src/test/recovery/t/010_logical_decoding_timelines.pl | added | +130 −0 |