Skip to content

Add rake geo:db:foreign_tables_out_of_date

What does this MR do?

This task is intended to be called by omnibus during reconfigure to determine if rake geo:db:refresh_foreign_tables should be run.

It is option 2 of omnibus-gitlab#4672 (comment 218542272):

  1. tell omnibus to run the check, and parse it to know if we need refresh
  2. or add a rake task that returns 1 if need refresh
  3. or guard rake geo:db:refresh_foreign_tables with the check, and always run the task on reconfigure

Although I did the inverse: rake geo:db:foreign_tables_out_of_date returns 0 if refresh is needed. It returns non-zero if not needed (or if any other error happens). This will avoid running the refresh task when errors are happening.

Screenshots

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team

Part of omnibus-gitlab#4672 (closed)

Merge request reports