Hello Alexander,
On 2024-Nov-14, Alexander Kukushkin wrote:
> The commit message looks good to me, except maybe using a "master" word,
> which I would suggest to replace with "primary".
Oh wow, thanks for noticing that. I had already rewritten the commit
message to some extent, but "master" had remained. Now I pushed the
patch to branches 14+, having replaced it as you suggested.
(This reminds me that I used to have a notification set in the
2ndQuadrant Mattermost instance so that I could LART anybody who used
the words 'master' or 'slave' in the chats there).
> + /*
> + * This hash table is empty in the vast majority of cases, so set an
> + * initial size of 0.
> + */
> + keepwal = keepwal_create(0, NULL);
> +}
>
> I don't think that the hash table will be empty. It needs to hold all WAL
> filenames starting from the last checkpoint and up to divergent point.
> On loaded clusters it could be hundreds and thousands of files.
Oh, okay. The initial size is just there to avoid having to grow the
hash table, but using the same constant that we use for the filemap hash
table seems good enough ... it shouldn't make much of a difference in
practice.
Regards
--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/
<Schwern> It does it in a really, really complicated way
<crab> why does it need to be complicated?
<Schwern> Because it's MakeMaker.