Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit a2b516d

Browse files
Only throw recovery conflicts when InHotStandby. Bug fix to recent
patch to allow Index Only Scans on Hot Standby. Bug report from Jaime Casanova
1 parent c8105e6 commit a2b516d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/backend/access/heap/heapam.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4725,7 +4725,8 @@ heap_xlog_visible(XLogRecPtr lsn, XLogRecord *record)
47254725
* forces any index-only scan that is in flight to perform heap fetches,
47264726
* rather than killing the transaction outright.
47274727
*/
4728-
ResolveRecoveryConflictWithSnapshot(xlrec->cutoff_xid, xlrec->node);
4728+
if (InHotStandby)
4729+
ResolveRecoveryConflictWithSnapshot(xlrec->cutoff_xid, xlrec->node);
47294730

47304731
LockBuffer(buffer, BUFFER_LOCK_EXCLUSIVE);
47314732

0 commit comments

Comments
 (0)