Assert that cutoffs are provided if freezing will be attempted
Melanie Plageman <melanieplageman@gmail.com>
Author:
Melanie Plageman <melanieplageman@gmail.com>
Date: 2025-11-25T21:41:29Z
Releases:
19 (unreleased)
Assert that cutoffs are provided if freezing will be attempted heap_page_prune_and_freeze() requires the caller to initialize PruneFreezeParams->cutoffs so that the function can correctly evaluate whether tuples should be frozen. This requirement previously existed only in comments and was easy to miss, especially after “cutoffs” was converted from a direct function parameter to a field of the newly introduced PruneFreezeParams struct (added in 1937ed70621). Adding an assert makes this requirement explicit and harder to violate. Also, fix a minor typo while we're at it. Author: Chao Li <li.evan.chao@gmail.com> Reviewed-by: Melanie Plageman <melanieplageman@gmail.com> Discussion: https://postgr.es/m/0AC177F5-5E26-45EE-B273-357C51212AC5%40gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/access/heap/pruneheap.c | modified | +4 −1 |
Discussion
- eliminate xl_heap_visible to reduce WAL (and eventually set VM on-access) 168 messages · 2025-06-23 → 2026-04-21