Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb2cc5b8

Browse files
author
Amit Kapila
committed
Remove the streaming files for incomplete xacts after restart.
After restart, we try to stream the changes for large transactions thatwere not sent before server crash and restart. However, we forget to sendthe abort message for such transactions. This leads to spurious streamingfiles on the subscriber which won't be cleaned till the apply worker orthe subscriber server restarts.Reported-by: Dilip KumarAuthor: Hou ZhijieReviewed-by: Dilip Kumar and Amit KapilaBackpatch-through: 14Discussion:https://postgr.es/m/OS0PR01MB5716A773F46768A1B75BE24394FB9@OS0PR01MB5716.jpnprd01.prod.outlook.com
1 parent48599a1 commitb2cc5b8

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

‎src/backend/replication/logical/reorderbuffer.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2898,6 +2898,10 @@ ReorderBufferAbortOld(ReorderBuffer *rb, TransactionId oldestRunningXid)
28982898
{
28992899
elog(DEBUG2,"aborting old transaction %u",txn->xid);
29002900

2901+
/* Notify the remote node about the crash/immediate restart. */
2902+
if (rbtxn_is_streamed(txn))
2903+
rb->stream_abort(rb,txn,InvalidXLogRecPtr);
2904+
29012905
/* remove potential on-disk data, and deallocate this tx */
29022906
ReorderBufferCleanupTXN(rb,txn);
29032907
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp