Re: XID formatting and SLRU refactorings

Aleksander Alekseev <aleksander@timescale.com>

From: Aleksander Alekseev <aleksander@timescale.com>
To: Postgres hackers <pgsql-hackers@lists.postgresql.org>
Cc: Pavel Borisov <pashkin.elfe@gmail.com>, Heikki Linnakangas <hlinnaka@iki.fi>, Alexander Korotkov <aekorotkov@gmail.com>, Maxim Orlov <orlovmg@gmail.com>, Japin Li <japinli@hotmail.com>, Andres Freund <andres@anarazel.de>, Michael Paquier <michael@paquier.xyz>, Peter Eisentraut <peter.eisentraut@enterprisedb.com>
Date: 2023-11-28T12:06:28Z
Lists: pgsql-hackers
Hi,

>> > I think what's done in patch 0001 is just an extension of existing
>> > logic and moving it into separate function.
>>
>> That's right. I'm arguing that now is a good time to clean it up.
>>
>> I won't insist if Alexander prefers to commit it as it is, though. But
>> let's at least explain how this works in the comment, instead of the XXX.
>
> I agree with you that would be good to add a comment instead of XXX and commit.

+1

One could argue that getting rid of short filenames entirely in the
long term (i.e. always long_segment_names == true) could be a better
strategy. Maybe it's not but I believe this should be discussed
separately from the patchset under question.

-- 
Best regards,
Aleksander Alekseev



Commits

  1. Fix more holes with SLRU code in need of int64 for segment numbers

  2. Use more consistently int64 for page numbers in SLRU-related code

  3. Improve comments in slru.{c,h} about segment name format

  4. Reorder actions in ProcArrayApplyRecoveryInfo()

  5. Fix typo in 5a1dfde8334b

  6. Fix warning due non-standard inline declaration in 4ed8f0913bfdb5f355

  7. Add SLRU tests for 64-bit page case

  8. Make use FullTransactionId in 2PC filenames

  9. Use larger segment file names for pg_notify

  10. Index SLRUs by 64-bit integers rather than by 32-bit integers

  11. Keep track of transaction commit timestamps

  12. Handle 5-char filenames in SlruScanDirectory