On Fri, Sep 18, 2026, Melanie Plageman wrote: > Pruning and freezing > always required a cleanup lock in recovery
Could 0002 use just do_prune instead of do_prune || do_freeze? The comment for XLHP_CLEANUP_LOCK allows freezing under an ordinary exclusive lock. Before pruning and freezing shared a WAL record, freeze-only replay in heap_xlog_freeze_page() used normal exclusive lock IIUC. With 0002 I observe VACUUM FREEZE on a page containing only live tuples to terminate a standby cursor holding a pin. Using just do_prune lets replay finish without canceling the cursor. 0001, 0003 and 0004 look good to me. I tried 0003/0004 with a manual primary/standby test, but found nothing interesting. Thank you! Best regards, Andrey Borodin.
