Re: pg_receivewal starting position
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: Ronan Dunklau <ronan.dunklau@aiven.io>
Cc: pgsql-hackers@lists.postgresql.org, Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>, Kyotaro Horiguchi <horikyota.ntt@gmail.com>, Masahiko Sawada <sawada.mshk@gmail.com>
Date: 2021-10-23T07:44:00Z
Lists: pgsql-hackers
Attachments
- v10-0001-Add-replication-command-READ_REPLICATION_SLOT.patch (text/x-diff) patch v10-0001
On Thu, Oct 21, 2021 at 10:36:42AM +0200, Ronan Dunklau wrote: > Done. I haven't touched the timeline switch test patch for now, but I still > include it here for completeness. Thanks. I have applied and back-patched 0001, then looked again at 0002 that adds READ_REPLICATION_SLOT: - Change the TLI to use int8 rather than int4, so as we will always be right with TimelineID which is unsigned (this was discussed upthread but I got back on it after more thoughts, to avoid any future issues). - Added an extra initialization for the set of Datum values, just as an extra safety net. - There was a bug with the timeline returned when executing the command while in recovery as ThisTimeLineID is 0 in the context of a standby, but we need to support the case of physical slots even when streaming archives from a standby. The fix is similar to what we do for IDENTIFY_SYSTEM, where we need to use the timeline currently replayed from GetXLogReplayRecPtr(), before looking at the past timeline history using restart_lsn and the replayed TLI. With that in place, I think that we are good now for this part. -- Michael
Commits
-
Add TAP test for pg_receivewal with timeline switch
- 0f9b9938a036 15.0 landed
-
Speed up TAP tests of pg_receivewal
- d680992af540 15.0 landed
-
Allow pg_receivewal to stream from a slot's restart LSN
- f61e1dd2cee6 15.0 landed
-
Add replication command READ_REPLICATION_SLOT
- b4ada4e19fd7 15.0 landed
-
doc: Describe calculation method of streaming start for pg_receivewal
- 438d467a5241 10.19 landed
- e6c5f1b45265 11.14 landed
- fb1aa489e481 12.9 landed
- 7c949f1b3aab 13.5 landed
- affec9f6a2de 14.1 landed
- 1e9475694b0a 15.0 landed
-
Add PostgresNode::command_fails_like()
- de1d4fef71cb 15.0 landed