Add further debug info to help debug 019_replslot_limit.pl failures.
authorAndres Freund <andres@anarazel.de>
Sat, 26 Feb 2022 00:58:48 +0000 (16:58 -0800)
committerAndres Freund <andres@anarazel.de>
Sat, 26 Feb 2022 01:04:39 +0000 (17:04 -0800)
commitfe0972ee5e6f8a663c5cf3f24ef98987c503da95
tree6e631076d93f18709b1a73e7a9eb719bbcff955d
parent638300fef541fb9393caa1ee8821a639816301d1
Add further debug info to help debug 019_replslot_limit.pl failures.

See also afdeff10526. Failures after that commit provided a few more hints,
but not yet enough to understand what's going on.

In 019_replslot_limit.pl shut down nodes with fast instead of immediate mode
if we observe the failure mode. That should tell us whether the failures we're
observing are just a timing issue under high load. PGCTLTIMEOUT should prevent
buildfarm animals from hanging endlessly.

Also adds a bit more logging to replication slot drop and ShutdownPostgres().

Discussion: https://postgr.es/m/20220225192941.hqnvefgdzaro6gzg@alap3.anarazel.de
src/backend/replication/slot.c
src/backend/storage/lmgr/lwlock.c
src/backend/utils/init/postinit.c
src/include/storage/lwlock.h
src/test/recovery/t/019_replslot_limit.pl