Fix instability in 031_recovery_conflict.pl.

Thomas Munro <tmunro@postgresql.org>

Commit: 0174c2d213f69a4ba87932de706eedf3fbb5979e
Author: Thomas Munro <tmunro@postgresql.org>
Date: 2023-09-07T02:38:15Z
Releases: 17.0
Fix instability in 031_recovery_conflict.pl.

Where the test wants a VACUUM command to generate WAL that would
conflict with a session on the standby, it could transiently fail to do
so if it couldn't acquire a cleanup lock conditionally at that moment on
the primary.  VACUUM FREEZE will wait, so use that instead.

No back-patch for now, but that will be needed if/when the test is
re-enabled in back-branches.

Suggested-by: Andres Freund <andres@anarazel.de>
Reported-by: Christoph Berg <myon@debian.org>
Discussion: https://postgr.es/m/20230812210006.ei7tutzwcr5svyt6%40awork3.anarazel.de

Files

PathChange+/−
src/test/recovery/t/031_recovery_conflict.pl modified +7 −7

Discussion