Re: Collation version tracking for macOS - Mailing list pgsql-hackers

From Tobias Bussmann
Subject Re: Collation version tracking for macOS
Date
Msg-id 59782113-8CE1-422C-88CA-961BE6733DC1@gmx.net
Whole thread Raw
In response to Re: Collation version tracking for macOS  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Am 08.06.2022 um 16:16 schrieb Tom Lane <tgl@sss.pgh.pa.us>:
> The proposed patch would result in a warning about every collation-
> sensitive index during every macOS major version upgrade, ie about
> once a year for most people.
> We need something that has at least *some* connection to actual changes.

In Postgres.app we introduced default collation versioning and warnings about possible mismatches from outside the
actualserver. When the user runs initdb with the GUI wrapper, the OS version and a checksum of the LC_COLLATE file of
theused default collation is stored as meta-data. This allows to display a reindex warning on startup if the hash
changesor we hardcode a known incompatible OS change. 

Having collversion support on macOS within postgres would leverage the existing infrastructure for version change
warningsand enables support for multiple collations. But I agree, we need something more specific than the major OS
versionhere. Lacking any collation version information from the provider, a checksum on the binary LC_COLLATE file is
thebest I can come up with.  

Best regards,
Tobias


pgsql-hackers by date:

Previous
From: Thomas Munro
Date:
Subject: Re: Collation version tracking for macOS
Next
From: Peter Geoghegan
Date:
Subject: Re: Collation version tracking for macOS