Re: removing global variable ThisTimeLineID
Drouvot, Bertrand <bdrouvot@amazon.com>
From: "Drouvot, Bertrand" <bdrouvot@amazon.com>
To: Robert Haas <robertmhaas@gmail.com>, Michael Paquier <michael@paquier.xyz>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2021-11-23T09:36:16Z
Lists: pgsql-hackers
Hi, On 11/8/21 6:49 PM, Robert Haas wrote: > On Mon, Nov 8, 2021 at 8:27 AM Robert Haas <robertmhaas@gmail.com> wrote: > Well I went through and it seems to be OK: all the existing callers of > that function first verify that we're not in recovery. The patch to > make logical decoding work in standby mode might change that, Indeed, I think the logical decoding on standby patch just needs to change the Assert in GetWALInsertionTimeLine() to check SharedRecoveryState is RECOVERY_STATE_DONE or RECOVERY_STATE_ARCHIVE. Would that make sense from your point of view to add the check on RECOVERY_STATE_ARCHIVE or do you think it would need to be more "sophisticated"? Thanks Bertrand
Commits
-
More cleanup of 'ThisTimeLineID'.
- a27048cbcb58 15.0 landed
-
Change ThisTimeLineID from a global variable to a local variable.
- 4a92a1c3d1c3 15.0 landed
-
Remove all use of ThisTimeLineID global variable outside of xlog.c
- e997a0c64286 15.0 landed
-
Don't set ThisTimeLineID when there's no reason to do so.
- caf1f675b88d 15.0 landed
-
When fetching WAL for a basebackup, report errors with a sensible TLI.
- 2f5c4397c39d 15.0 cited
-
Remove useless code from CreateReplicationSlot.
- 902a2c280012 15.0 cited