Commit 8238123b authored by Alex Hanselka's avatar Alex Hanselka Committed by Mike Jang

Add note about feature flags being on by default

We had an incident recently with an on by default feature causing
issues in production
https://gitlab.com/gitlab-com/gl-infra/production/-/issues/2442
parent 15f0683e
......@@ -32,8 +32,11 @@ request removing the feature flag or the merge request where the default value o
the feature flag is set to true. If the feature contains any DB migration it
should include a changelog entry for DB changes.
If you need the feature flag to be on automatically, use `default_enabled: true`
when checking:
NOTE: **Note:**
All newly-introduced feature flags should be [off by default](./process.md#feature-flags-in-gitlab-development).
In rare cases you may need to set the feature flag on by default. If so, please explain the reasoning
in the merge request. To enable an active feature flag, use `default_enabled: true` when checking:
```ruby
Feature.enabled?(:feature_flag, project, default_enabled: true)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment