Skip to content

Add gitlab.rails.application_settings_cache_seconds config variable

Mark Lapierre requested to merge ml-add-application-settings-cache-config into main

What does this merge request do and why?

Adds config for GitLab's application settings cache, like the config for omnibus-gitlab. It's needed in e2e tests to disable the cache to prevent test flakiness when settings (including feature flags) are toggled on and off.

See also gitlab#217010 (closed)

How to set up and validate locally

  1. Adding the below configuration in gdk.yml:
    gitlab:
      rails:
         application_settings_cache_seconds: 0
  2. Check out to this merge request's branch.
  3. Run gdk reconfigure to check if regenerating all configuration is successful.

The change should be similar to:

'gitlab/config/gitlab.yml' has incoming changes:
-------------------------------------------------------------------------------------------------------------
@@ -108,6 +108,9 @@ production: &base
     ## Impersonation settings
     impersonation_enabled: true

+    ## Application settings cache expiry in seconds (default: 60)
+    application_settings_cache_seconds: 0
+
   ## Reply by email
   # Allow users to comment on issues and merge requests by replying to notification emails.
   # For documentation on how to set this up, see http://doc.gitlab.com/ce/administration/reply_by_email.html

-------------------------------------------------------------------------------------------------------------

Compare with gitlab/config/gitlab.yml.example.

Impacted categories

The following categories relate to this merge request:

Merge request checklist

  • This change is backward compatible. If not, please include steps to communicate to our users.
  • Tests added for new functionality. If not, please raise an issue to follow-up.
  • Documentation added/updated, if needed.
  • Announcement added, if change is notable.
  • gdk doctor test added, if needed.
  • Add the ~highlight label if this MR should be included in the CHANGELOG.md.
Edited by Mark Lapierre

Merge request reports

Loading