Upgrade PostgreSQL driver to v5
The container registry uses github.com/jackc/pgx as the PostgreSQL driver/toolkit in order to interact with the metadata database. In September 2022, a new major version (v5) was released: https://github.com/jackc/pgx/blob/master/CHANGELOG.md#v500-september-17-2022.
We're currently running v4. There have been some significant changes in this new major version, so we need to ensure everything remains functional and adapt to any API breaking changes.
Required steps:
-
Upgrade dependency to v5. As said in the linked changelog, several external dependencies (that we also rely on) are now integrated within github.com/jackc/pgx. The upgrade should reflect that as well; -
Compile registry application and check for errors (due to API breaking changes); -
Fix errors that arise from the above, if any; -
Run all database unit and integration tests (see all database:*sections in the.gitlab-ci.ymlfile) and ensure all succeed both locally and on GitLab CI.