pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Report syncscan position at end of scan. 2+ messages / 1 participants [nested] [flat]
* pgsql: Report syncscan position at end of scan. @ 2023-08-31 10:11 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 2+ messages in thread From: Heikki Linnakangas @ 2023-08-31 10:11 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Report syncscan position at end of scan. The comment in heapgettup_advance_block() says that it reports the scan position before checking for end of scan, but that didn't match the code. The code was refactored in commit 7ae0ab0ad9, which inadvertently changed the order of the check and reporting. Change it back. This caused a few regression test failures with a small shared_buffers setting like 10 MB. The 'portals' and 'cluster' tests perform seqscans that are large enough that sync seqscans kick in. When the sync scan position is not updated at end of scan, the next seq scan doesn't start at the beginning of the table, and the test queries are sensitive to that. Reviewed-by: Melanie Plageman, David Rowley Discussion: https://www.postgresql.org/message-id/6f991389-ae22-d844-a9d8-9aceb7c01a9a@iki.fi Backpatch-through: 16 Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/e8d74ad625f7344f6b715254d3869663c1569a51 Modified Files -------------- src/backend/access/heap/heapam.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 2+ messages in thread
* pgsql: Report syncscan position at end of scan. @ 2023-08-31 10:11 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 2+ messages in thread From: Heikki Linnakangas @ 2023-08-31 10:11 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Report syncscan position at end of scan. The comment in heapgettup_advance_block() says that it reports the scan position before checking for end of scan, but that didn't match the code. The code was refactored in commit 7ae0ab0ad9, which inadvertently changed the order of the check and reporting. Change it back. This caused a few regression test failures with a small shared_buffers setting like 10 MB. The 'portals' and 'cluster' tests perform seqscans that are large enough that sync seqscans kick in. When the sync scan position is not updated at end of scan, the next seq scan doesn't start at the beginning of the table, and the test queries are sensitive to that. Reviewed-by: Melanie Plageman, David Rowley Discussion: https://www.postgresql.org/message-id/6f991389-ae22-d844-a9d8-9aceb7c01a9a@iki.fi Backpatch-through: 16 Branch ------ REL_16_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/d5feb6011e629cc1096bbaa10af5ffcc6c17f908 Modified Files -------------- src/backend/access/heap/heapam.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2023-08-31 10:11 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2023-08-31 10:11 pgsql: Report syncscan position at end of scan. Heikki Linnakangas <heikki.linnakangas@iki.fi> 2023-08-31 10:11 pgsql: Report syncscan position at end of scan. Heikki Linnakangas <heikki.linnakangas@iki.fi>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox