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

Commit397cd0b

Browse files
author
Amit Kapila
committed
Remove redundant fetch of the recent flush pointer in WalSndWaitForWal.
In WalSndWaitForWal(), we fetch a recent flush pointer both outside theloop and inside the loop. But we start using RecentFlushPtr only after wefetch it inside the loop. So we can remove one outside the loop.Author: Shveta MalikReviewed-by: Bertrand Drouvot, Matthias van de Meent, Amit KapilaDiscussion:https://postgr.es/m/CAJpy0uBSCQz1yMD-WiEthzEe23dti2-Kr_pitVb7vAPFbFKm=A@mail.gmail.com
1 parent2c8118e commit397cd0b

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

‎src/backend/replication/walsender.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1831,12 +1831,6 @@ WalSndWaitForWal(XLogRecPtr loc)
18311831
!NeedToWaitForWal(loc,RecentFlushPtr,&wait_event))
18321832
returnRecentFlushPtr;
18331833

1834-
/* Get a more recent flush pointer. */
1835-
if (!RecoveryInProgress())
1836-
RecentFlushPtr=GetFlushRecPtr(NULL);
1837-
else
1838-
RecentFlushPtr=GetXLogReplayRecPtr(NULL);
1839-
18401834
/*
18411835
* Within the loop, we wait for the necessary WALs to be flushed to disk
18421836
* first, followed by waiting for standbys to catch up if there are enough

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp