public inbox for [email protected]  
help / color / mirror / Atom feed
From: Heikki Linnakangas <[email protected]>
To: Aleksander Alekseev <[email protected]>
To: [email protected]
Cc: Rustam ALLAKOV <[email protected]>
Cc: Michael Paquier <[email protected]>
Subject: Re: [PATCH] Refactor SLRU to always use long file names
Date: Tue, 6 Jan 2026 17:28:25 +0200
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAJ7c6TNqaK3R52KiSaR78p7OkC=kccO4FHZaff7F9ijz36ihsw@mail.gmail.com>
References: <CAJ7c6TOy7fUW9MuNeOWor3cSFnQg9tgz=mjXHDb94GORtM_Eyg@mail.gmail.com>
	<CAJ7c6TNu+5m2gBgRoSQ6jEJHzuxDf7JsZy9Y6K67ZynyZ5sfKg@mail.gmail.com>
	<174319365391.60294.17413945943923890743.pgcf@coridan.postgresql.org>
	<CAJ7c6TP6aNSL3Q33wuqOPf1LxgxCmm1q-u4OVH5RksB49W_kFQ@mail.gmail.com>
	<CAJ7c6TMQUp5p0njUtJR37J7Pg4Gry0FDAVzOL50tT1HX=-BKrQ@mail.gmail.com>
	<CAJ7c6TNqaK3R52KiSaR78p7OkC=kccO4FHZaff7F9ijz36ihsw@mail.gmail.com>

On 06/01/2026 17:18, Aleksander Alekseev wrote:
> +static void
> +check_slru_segment_filenames(void)
> +{
> +	int i;
> +	static const char* dirs[] = {
> +		"pg_xact",
> +		"pg_commit_ts",
> +		"pg_multixact/offsets",
> +		"pg_multixact/members",
> +		"pg_subtrans",
> +		"pg_serial",
> +	};
> +
> +	if(old_cluster.controldata.cat_ver >= SLRU_SEG_FILENAMES_CHANGE_CAT_VER)
> +		return;
> +
> +	for (i = 0; i < sizeof(dirs)/sizeof(dirs[0]); i++)
> +		rename_slru_segments(dirs[i]);
> +}

Since commit bd8d9c9bdf "Widen MultiXactOffset to 64 bits", 
"pg_multixact/members" should not be in that list anymore.

Also, it seems misleading that a function called "check_*" doesn't 
merely check for things, but renames files. Also, it seems silly to 
first copy/link the files with the old short names, and rename them 
later. Could we copy/link them with the new long names to begin with?

(No comment on whether this is a good idea in general or the rest of the 
patch)

- Heikki







view thread (9+ messages)  latest in thread

reply

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: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: [PATCH] Refactor SLRU to always use long file names
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox