]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Disable logical decoding after REPACK (CONCURRENTLY)
authorÁlvaro Herrera <alvherre@kurilemu.de>
Wed, 27 May 2026 18:11:21 +0000 (20:11 +0200)
committerÁlvaro Herrera <alvherre@kurilemu.de>
Wed, 27 May 2026 18:11:29 +0000 (20:11 +0200)
commit2af1dc89282bea681201cf66e2bb32537294e623
treee801887abd836bb1456ce55f0ac6a4afdc6e961e
parent0f24332aeb4f43409c2a7bec9fef1e3317689bc5
Disable logical decoding after REPACK (CONCURRENTLY)

REPACK (CONCURRENTLY) uses a temporary logical replication slot, which
is dropped once done, but it wasn't calling RequestDisableLogicalDecoding(),
leaving effective_wal_level stuck at 'logical'.

Fix by adding a Boolean flag to ReplicationSlotDropAcquired() to have it
request to disable logical decoding, and passing it as true on REPACK.
Other callers of that function preserve their existing behavior.

Author: Imran Zaheer <imran.zhir@gmail.com>
Reviewed-by: shveta malik <shveta.malik@gmail.com>
Discussion: https://postgr.es/m/CA+UBfaktds57dw2M8BEv_kS-=ixph3w+3MxKixtaDQMi_k7Ybg@mail.gmail.com
src/backend/commands/repack_worker.c
src/backend/replication/logical/launcher.c
src/backend/replication/logical/slotsync.c
src/backend/replication/slot.c
src/include/replication/slot.h
src/test/recovery/t/051_effective_wal_level.pl