pgsql: Add read_stream_{pause,resume}() - Mailing list pgsql-committers

From Melanie Plageman
Subject pgsql: Add read_stream_{pause,resume}()
Date
Msg-id E1vxWv1-002F5e-1B@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Add read_stream_{pause,resume}()

Read stream users can now pause lookahead when no blocks are currently
available. After resuming, subsequent read_stream_next_buffer() calls
continue lookahead with the previous lookahead distance.

This is especially useful for read stream users with self-referential
access patterns (where consuming already-read buffers can produce
additional block numbers).

Author: Thomas Munro <thomas.munro@gmail.com>
Reviewed-by: Melanie Plageman <melanieplageman@gmail.com>
Reviewed-by: Nazir Bilal Yavuz <byavuz81@gmail.com>
Discussion: https://postgr.es/m/CA%2BhUKGJLT2JvWLEiBXMbkSSc5so_Y7%3DN%2BS2ce7npjLw8QL3d5w%40mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/38229cb905165fe676ab8728cb9dd0833a5534ed

Modified Files
--------------
src/backend/storage/aio/read_stream.c | 27 +++++++++++++++++++++++++++
src/include/storage/read_stream.h     |  2 ++
2 files changed, 29 insertions(+)


pgsql-committers by date:

Previous
From: Peter Eisentraut
Date:
Subject: pgsql: doc: Add restart on failure to example systemd file
Next
From: Michael Paquier
Date:
Subject: pgsql: Add some tests for CREATE OR REPLACE VIEW with column additions