Skip to content
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

support PostgreSQL 16 #564

Merged
merged 11 commits into from
Jan 19, 2024
Merged

support PostgreSQL 16 #564

merged 11 commits into from
Jan 19, 2024

Conversation

conscribtor
Copy link
Contributor

@conscribtor conscribtor commented Dec 27, 2023

  • Add the necessary configuration templates to support PostgreSQL 16 installations.
  • Update documentation (readme, role defaults, templates, ...)

resolves #565

There were discrepancies between the postgresql.conf templates in the repository and the most
current templates. The templates where thus refreshed to make comparisons between versions easier.
In summary, the following was changed:
- user customisations were reset to package defaults (log handling, port, ...)
- backported settings and comments were included (data_sync_retry, krb_server_keyfile, ...)
- role customisation were reset to package defaults (includes)
- The postgresql.conf-16.j2 template was compiled from its package template.
- Added postgres 16 settings the role defaults. (>= 16)
- Annotated deprecated role defaults. (<= 15)
- added missing required version hints for previous posgres versions 11, 12 and 13
- removed incorrect hints on:
  - postgresql_data_sync_retry: off is default for 10-16
  - postgresql_extension_destdir: "" is default for 10-16
  - postgresql_gin_fuzzy_search_limit: 0 is default for 10-16
- added comments from templates to some defaults
@MrMegaNova
Copy link
Collaborator

Thanks for your work, can you please reopen this PR to pull on dev branch ?

@conscribtor conscribtor changed the base branch from master to development December 27, 2023 15:33
@conscribtor
Copy link
Contributor Author

conscribtor commented Dec 27, 2023

Thanks for your work, can you please reopen this PR to pull on dev branch ?

I've changed the base branch to development. I hope this has the intended result, I'm more familiar with GitLab ;-).
I can additionally rebase my fork on dev if necessary.

@MrMegaNova MrMegaNova self-assigned this Jan 9, 2024
@MrMegaNova
Copy link
Collaborator

Hi thanks for your quick reply
I haven't seen the reply notification, sorry for the delay.

@conscribtor
Copy link
Contributor Author

conscribtor commented Jan 9, 2024

@MrMegaNova

Hi thanks for your quick reply I haven't seen the reply notification, sorry for the delay.

No problem. It was that time of the year anyway. 🥳
Thank you for running the CI. It seems that due to the issue raised in #566, it can't succeed. Also, it seems that they have moved the location of the GPG for yum: https://yum.postgresql.org/news/pgdg-rpm-repo-gpg-key-update/.

I'll try to fix this, but I might have to extend the scope to include the removal of PG11 to make it work. Would that be okay?

I'll be working in the conditional defaults as discussed in #565 (comment).

@MrMegaNova MrMegaNova marked this pull request as ready for review January 10, 2024 09:33
@MrMegaNova
Copy link
Collaborator

Thanks for your proposal, we want to drop testing on postgresql 11 on every distro.
I will create a new PR myself to to do it, you will be able to import my commit to fix this issue.

Due to changes in 8bc5ff2, on Ubuntu 22.04 installations variables from Debian_22.yml are imported
instead of Debian.yml. This leads to postgresql_service_name not being set and thus, the playbook
was unable to reload the service on configuration changes.
@conscribtor
Copy link
Contributor Author

conscribtor commented Jan 16, 2024

I've noticed that on my Ubuntu 22.04 a few variables are not set due to Debian_22.yml not containing them. Due to the missing postgresql_service_name the Reload PostgreSQL configuration task will error out.
This is skipped in the tests and thus won't be detected.

I hope it's okay that I included this in this MR, since without it I'm unable to test my changes.
Due to the missing postgresql_bin_directory the tasks that add database extensions won't work on Ubuntu 22.04 either. Shall I add them?

On the 3 January 2024, PostgreSQL has updated their RPM GPG keys:
https://yum.postgresql.org/news/pgdg-rpm-repo-gpg-key-update/
@conscribtor
Copy link
Contributor Author

conscribtor commented Jan 16, 2024

Also, it seems that they have moved the location of the GPG for yum: https://yum.postgresql.org/news/pgdg-rpm-repo-gpg-key-update/.

I've pushed bf99ff3 to address this and successfully smoke tested with the test playbook on Rocky Linux 9, Debian 12, Ubuntu 22.04 and CentOS 8.

@MrMegaNova
Copy link
Collaborator

Hi @conscribtor ,
You've done right, I've encounter the same problem with gpg key for pgdg during testing.
I've used your commit to fix this on my MR: #567
I've done some work removing testing on pg 11 and cleaning compatibility matrix.
I'm ready to add testing on pg 16 if you haven't already done that on your MR.

I'm gonna merge #567, then I will review one more time your MR and merge it
@tsoulabail If you have some time to double review this PR and approve it, it would be nice

@MrMegaNova
Copy link
Collaborator

MrMegaNova commented Jan 17, 2024

About the conflict, you''ve done right using ⛔ instead of ⁉️ on pg 10 & 11
So you can resolve this way.
I also think about removing old versions like pg 10 and Ubuntu 16.04, 18.04, CentOS 7.x and Fedora 37 so if you think the same way, you can do that too.

@conscribtor
Copy link
Contributor Author

I've merged the current development branch into this PR's branch.

I think that we should leave only the last EOL PostgreSQL version in the table. The user can then safely infer that all versions older than that are also EOL.

I've included your proposed removal of EOL operating systems, since I think that repositories and GPG keys may become unavailable at any moment, which will lead to confusion if it is marked as working in the matrix.

I've also removed Debian 10, since it is now under LTS support (comparable to Ubuntu's 18.04 Expanded Security Maintenance that ends in 2028).

@conscribtor
Copy link
Contributor Author

conscribtor commented Jan 17, 2024

@MrMegaNova

I'm ready to add testing on pg 16 if you haven't already done that on your MR.

I'd be happy to leave that to you. I'm unexperienced with Molecule tests.

@MrMegaNova
Copy link
Collaborator

Good job !
I will add pg16 testing before merging

@MrMegaNova MrMegaNova merged commit 64b3da6 into ANXS:development Jan 19, 2024
4 checks passed
@conscribtor conscribtor deleted the pg16 branch January 19, 2024 19:27
@gclough
Copy link
Collaborator

gclough commented Mar 27, 2024

@conscribtor, I just wanted to say thanks for helping out on this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: In progress
Development

Successfully merging this pull request may close these issues.

support PostgreSQL 16
3 participants