From: Michael Paquier <michael@paquier.xyz>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: pg_rewind: Extend code detecting relation files to work with WAL
Date: Thu, 23 Oct 2025 07:00:15 +0000
Message-ID: <E1vBpJ1-0035Ca-1q@gemulon.postgresql.org> (raw)
pg_rewind: Extend code detecting relation files to work with WAL files
isRelDataFile() is renamed to getFileContentType(), extended so as it
becomes able to detect more file patterns than only relation files. The
new file name pattern that can be detected is WAL files.
This refactoring has been suggested by Robert Haas. This will be used
in a follow-up patch where we are looking at improving how WAL files are
processed by pg_rewind. As of this change, WAL files are still handled
the same way as previously, always copied from the source to the target
server.
Extracted from a larger patch by the same authors.
Author: John Hsu <johnhyvr@gmail.com>
Author: Justin Kwan <justinpkwan@outlook.com>
Reviewed-by: Japin Li <japinli@hotmail.com>
Reviewed-by: Srinath Reddy Sadipiralla <srinath2133@gmail.com>
Discussion: https://postgr.es/m/181b4c6fa9c.b8b725681941212.7547232617810891479@viggy28.dev
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/6ae08d9583e9a5e951286948bdd9fcd58e67718a
Modified Files
--------------
src/bin/pg_rewind/filemap.c | 60 ++++++++++++++++++++++++++--------------
src/bin/pg_rewind/filemap.h | 9 +++++-
src/tools/pgindent/typedefs.list | 1 +
3 files changed, 48 insertions(+), 22 deletions(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-committers@postgresql.org
Cc: michael@paquier.xyz, pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: pg_rewind: Extend code detecting relation files to work with WAL
In-Reply-To: <E1vBpJ1-0035Ca-1q@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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