Skip to content
Snippets Groups Projects
Commit 1b3e271b authored by Alex Hanselka's avatar Alex Hanselka
Browse files

Add note about feature flags being on by default

We had an incident recently with an on by default feature causing
issues in production
gitlab-com/gl-infra/production#2442
parent 3625ab69
No related branches found
No related tags found
No related merge requests found
......@@ -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:
All feature flags should be [off by default](https://docs.gitlab.com/ee/development/feature_flags/process.html#feature-flags-in-gitlab-development).
In rare cases it may be necessary to have the feature flag on by default. If you
do determine that a feature flag should be on by default, please explain the reasoning
in the merge request. In order for the flag to be on automatically, use
`default_enabled: true` when checking:
```ruby
Feature.enabled?(:feature_flag, project, default_enabled: true)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment