Force rake gitlab:backup:restore to ignore PG16 must be able to SET ROLE "gitlab-psql" error

What does this MR do and why?

What

  • Adds rule to ignore output log message must be able to SET ROLE "gitlab-psql" when backup rake tasks fetch or load SQL dumps of databases

Why

  • PG16 introduced a slight change to the rules around updating role permissions on functions that is resulting in a new unexpected error message during pgdump operations when it executes the line ALTER FUNCTION public.pg_shadow_lookup(i_username text, OUT username text, OUT password text) OWNER TO "gitlab-psql"; at the end of the SQL dumps.
  • However, the error is inconsequential because we do fix all the ownership and permissions in the database after the backup is restored
  • We add this error message to the ignored errors list to prevent it as being reported as a fatal error loading the database data to the end user and interrupting the backup restoration rake task

References

Screenshots or screen recordings

Before After

How to set up and validate locally

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #542965 (closed)

Edited by Kyle Yetter

Merge request reports

Loading