]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Update minimum recovery point on truncation during WAL replay of abort record.
authorFujii Masao <fujii@postgresql.org>
Wed, 28 Jul 2021 16:30:02 +0000 (01:30 +0900)
committerFujii Masao <fujii@postgresql.org>
Wed, 28 Jul 2021 16:33:33 +0000 (01:33 +0900)
commitf2a3d7404e5d4aa17dbdf7299b1f0d548fe59b9d
tree42d44ccf92d2a288a7e7be23f87956e531e0f79f
parentfc0d9b8c224ff6b84113cefdca1ba9dde879d863
Update minimum recovery point on truncation during WAL replay of abort record.

If a file is truncated, we must update minRecoveryPoint. Once a file is
truncated, there's no going back; it would not be safe to stop recovery
at a point earlier than that anymore.

Commit 7bffc9b7bf changed xact_redo_commit() so that it updates
minRecoveryPoint on truncation, but forgot to change xact_redo_abort().

Back-patch to all supported versions.

Reported-by: mengjuan.cmj@alibaba-inc.com
Author: Fujii Masao
Reviewed-by: Heikki Linnakangas
Discussion: https://postgr.es/m/b029fce3-4fac-4265-968e-16f36ff4d075.mengjuan.cmj@alibaba-inc.com
src/backend/access/transam/xact.c