Skip to content

Commit 5c54f63

Browse files
Fix rare missing cancellations in Hot Standby.
The machinery around XLOG_HEAP2_CLEANUP_INFO failed to correctly pass through the necessary information on latestRemovedXid, avoiding cancellations in some infrequent concurrent update/cleanup scenarios. Backpatchable fix to 9.0 Detailed bug report and fix by Noah Misch, backpatchable version by me.
1 parent bd6aca8 commit 5c54f63

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/backend/access/heap/pruneheap.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ heap_page_prune(Relation relation, Buffer buffer, TransactionId OldestXmin,
173173
* initialize the rest of our working state.
174174
*/
175175
prstate.new_prune_xid = InvalidTransactionId;
176-
prstate.latestRemovedXid = InvalidTransactionId;
176+
prstate.latestRemovedXid = *latestRemovedXid;
177177
prstate.nredirected = prstate.ndead = prstate.nunused = 0;
178178
memset(prstate.marked, 0, sizeof(prstate.marked));
179179

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy