pgsql: Refactor sharedfileset.c to separate out fileset implementation.

From: Amit Kapila <akapila(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Refactor sharedfileset.c to separate out fileset implementation.
Date: 2021-08-30 03:39:34
Message-ID: E1mKY90-0003ZU-MP@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Refactor sharedfileset.c to separate out fileset implementation.

Move fileset related implementation out of sharedfileset.c to allow its
usage by backends that don't want to share filesets among different
processes. After this split, fileset infrastructure is used by both
sharedfileset.c and worker.c for the named temporary files that survive
across transactions.

Author: Dilip Kumar, based on suggestion by Andres Freund
Reviewed-by: Hou Zhijie, Masahiko Sawada, Amit Kapila
Discussion: https://postgr.es/m/E1mCC6U-0004Ik-Fs@gemulon.postgresql.org

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/dcac5e7ac157964f71f15d81c7429130c69c3f9b

Modified Files
--------------
src/backend/replication/logical/launcher.c | 3 +
src/backend/replication/logical/worker.c | 82 ++++++----
src/backend/storage/file/Makefile | 1 +
src/backend/storage/file/buffile.c | 84 +++++-----
src/backend/storage/file/fd.c | 2 +-
src/backend/storage/file/fileset.c | 205 ++++++++++++++++++++++++
src/backend/storage/file/sharedfileset.c | 244 +----------------------------
src/backend/utils/sort/logtape.c | 8 +-
src/backend/utils/sort/sharedtuplestore.c | 5 +-
src/include/replication/worker_internal.h | 1 +
src/include/storage/buffile.h | 14 +-
src/include/storage/fileset.h | 40 +++++
src/include/storage/sharedfileset.h | 14 +-
src/tools/pgindent/typedefs.list | 1 +
14 files changed, 368 insertions(+), 336 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Michael Paquier 2021-08-30 04:27:22 Re: pgsql: psql: Add test for query canceling
Previous Message Masahiko Sawada 2021-08-30 01:12:07 Re: Separate out FileSet from SharedFileSet (was Re: pgsql: pgstat: Bring up pgstat in BaseInit() to fix uninitialized use o)