Skip to content

Build with the ICU collation provider #470

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from Jul 27, 2018
Merged

Build with the ICU collation provider #470

merged 2 commits into from Jul 27, 2018

Conversation

ghost
Copy link

@ghost ghost commented Jul 22, 2018

This builds PostgreSQL with the ICU collation provider:
https://www.postgresql.org/docs/10/static/collation.html

@tianon
Copy link
Member

tianon commented Jul 23, 2018

Can you please provide some more detail about why you believe we should change this?

Reading through https://www.postgresql.org/docs/10/static/collation.html#COLLATION-MANAGING, it seems like icu isn't necessary recommended but is simply provided as an optional alternative, so IMO sticking to the default provided by upstream makes more sense.

@yosifkit
Copy link
Member

Minor 👍 from me since it has been enabled since the first 10 devel release on Debian: https://salsa.debian.org/postgresql/postgresql/blob/654f23890eccbca9389e84b0673d228d971d2d73/debian/changelog#L223

@ghost
Copy link
Author

ghost commented Jul 23, 2018

Hello Tianon,

This is for compatibility with:

I have also noticed that Heroku's PostgreSQL servers are configured --with-icu.

Alpine Linux' postgresql package is not configured --with-icu. However, ICU is not that big of a library, so I think that the improved compatibility would be worth the increased image size.

PostgreSQL's ICU support is really convenient for ensuring consistent collation.

Daniel

@ghost
Copy link
Author

ghost commented Jul 24, 2018

It looks like ICU support is also enabled in RPMs from the official PostgreSQL RPM repository:
https://git.postgresql.org/gitweb/?p=pgrpms.git;a=blob;f=rpm/redhat/10/postgresql/master/postgresql-10.spec;hb=HEAD

EDIT Yes, I can confirm. I used PostgreSQL RPM Building Project's Fedora28 RPM (https://download.postgresql.org/pub/repos/yum/testing/10/fedora/fedora-28-x86_64/pgdg-fedora10-10-4.noarch.rpm) and a Dockerfile based on https://git.postgresql.org/gitweb/?p=pgrpms.git;a=blob;f=docker/Dockerfile-Fedora25-PG10;h=fa6d0e600d5b1d3341f69217a41a531b3dbc6efd;hb=HEAD After building the image and running it, I was able to create a COLLATION using the 'icu' provider.

@tianon
Copy link
Member

tianon commented Jul 25, 2018

Ah, thanks for clarifying @dtrebbien -- we should indeed enable this then, but we'll need to fix update.sh to do so only on PostgreSQL 10+ (since support for ICU appears to not have been added until PostgreSQL 10). Would you like me to take over from here and get the necessary changes to the templating implemented?

@ghost
Copy link
Author

ghost commented Jul 25, 2018

Okay.

I have switched on "Allow edits from maintainers." if you need that. (I'm not sure what this does, to be honest, but it sounds like it could be useful.)

You are correct that ICU support was introduced in PostgreSQL 10: https://www.postgresql.org/docs/10/static/release-10.html#id-1.11.6.9.5.13

@tianon
Copy link
Member

tianon commented Jul 27, 2018

I have switched on "Allow edits from maintainers." if you need that. (I'm not sure what this does, to be honest, but it sounds like it could be useful.)

That's perfect, thanks. Pushed up the minor additional change. 👍

@tianon
Copy link
Member

tianon commented Jul 27, 2018

Merging since it was green on the previous commit and the new commit only modifies update.sh.

@tianon tianon merged commit 639f83f into docker-library:master Jul 27, 2018
tianon added a commit to infosiftr/stackbrew that referenced this pull request Jul 27, 2018
- `buildpack-deps`: remove `artful` (EOL)
- `julia`: add 0.7.0-beta2
- `openjdk`: 11-ea+24, 10.0.2, 8u181 (Windows)
- `percona`: add arches (`i386`)
- `postgres`: add `icu-dev` (docker-library/postgres#470)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants