🌐 AI搜索 & 代理 主页
Skip to content

Commit 0bdc777

Browse files
committed
Clear 'xid' in dummy async notify entries written to fill up pages
Before we started to freeze async notify entries (commit 8eeb4a0), no one looked at the 'xid' on an entry with invalid 'dboid'. But now we might actually need to freeze it later. Initialize them with InvalidTransactionId to begin with, to avoid that work later. Álvaro pointed this out in review of commit 8eeb4a0, but I forgot to include this change there. Author: Álvaro Herrera <alvherre@kurilemu.de> Discussion: https://www.postgresql.org/message-id/202511071410.52ll56eyixx7@alvherre.pgsql Backpatch-through: 14
1 parent 797e9ea commit 0bdc777

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/backend/commands/async.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1418,6 +1418,7 @@ asyncQueueAddEntries(ListCell *nextNotify)
14181418
*/
14191419
qe.length = QUEUE_PAGESIZE - offset;
14201420
qe.dboid = InvalidOid;
1421+
qe.xid = InvalidTransactionId;
14211422
qe.data[0] = '\0'; /* empty channel */
14221423
qe.data[1] = '\0'; /* empty payload */
14231424
}

0 commit comments

Comments
 (0)