Re: pgsql: Handle the "und" locale in ICU versions 54 and older. - Mailing list pgsql-committers

From Jeff Davis
Subject Re: pgsql: Handle the "und" locale in ICU versions 54 and older.
Date
Msg-id cb64fcc302ea562d31fce3efa89fc3991b908751.camel@j-davis.com
Whole thread Raw
In response to Re: pgsql: Handle the "und" locale in ICU versions 54 and older.  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-committers
On Thu, 2023-03-23 at 13:25 -0400, Tom Lane wrote:
> Hmm, should we back-patch this?  Seems like existing branches would
> be even more at risk than v16, because more likely to be built with
> old ICU.  OTOH, we do also run the risk of breaking installations
> that weren't broken before.

I wondered the same thing[1] but ultimately figured the risk outweighed
the reward. My reasoning (which I didn't post before) was:

If a user currently has a collation with locale 'und', and ICU <= 54,
they are getting their actual locale from the environment. If we
backpatch, it will silently change their locale to be the root locale,
which could be different, and break their indexes. That seems too
dangerous for a minor release.

For a major release it's more tolerable to put something like that in
the release notes.

Fortunately, I think most users now are probably using the built-in
collations, or using the empty string before an "@" to specify the root
locale, which works in all ICU versions. Users would only specify it as
"und" if they happen to know about language tags.

Regards,
    Jeff Davis

[1]
https://www.postgresql.org/message-id/9afa6dbe0d31053ad265aeba488fde784fd5b7ab.camel@j-davis.com



pgsql-committers by date:

Previous
From: Andres Freund
Date:
Subject: Re: pgsql: meson: add install-{quiet, world} targets
Next
From: Tom Lane
Date:
Subject: pgsql: Invent GENERIC_PLAN option for EXPLAIN.