Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
c8ce1f0d
Commit
c8ce1f0d
authored
Jun 29, 2017
by
Rémy Coutable
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Document the feature groups
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
53af1eb7
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
3 deletions
+18
-3
doc/api/README.md
doc/api/README.md
+1
-0
doc/api/features.md
doc/api/features.md
+1
-1
doc/development/feature_flags.md
doc/development/feature_flags.md
+16
-2
No files found.
doc/api/README.md
View file @
c8ce1f0d
...
...
@@ -17,6 +17,7 @@ following locations:
-
[
Deploy Keys
](
deploy_keys.md
)
-
[
Environments
](
environments.md
)
-
[
Events
](
events.md
)
-
[
Feature flags
](
features.md
)
-
[
Gitignores templates
](
templates/gitignores.md
)
-
[
GitLab CI Config templates
](
templates/gitlab_ci_ymls.md
)
-
[
Groups
](
groups.md
)
...
...
doc/api/features.md
View file @
c8ce1f0d
# Features API
# Features
flags
API
All methods require administrator authorization.
...
...
doc/development/feature_flags.md
View file @
c8ce1f0d
...
...
@@ -3,5 +3,19 @@
Starting from GitLab 9.3 we support feature flags via
[
Flipper
](
https://github.com/jnunemaker/flipper/
)
. You should use the
`Feature`
class (defined in
`lib/feature.rb`
) in your code to get, set and list feature
flags. During runtime you can set the values for the gates via the
[
admin API
](
../api/features.md
)
.
flags.
During runtime you can set the values for the gates via the
[
features API
](
../api/features.md
)
(
accessible
to admins only).
## Feature groups
Starting from GitLab 9.4 we support feature groups via
[
Flipper groups
](
https://github.com/jnunemaker/flipper/blob/v0.10.2/docs/Gates.md#2-group
)
.
Feature groups must be defined statically in
`lib/feature.rb`
(in the
`.register_feature_groups`
method), but their implementation can obviously be
dynamic (querying the DB etc.). You can see how the
`performance_team`
feature
group for a concrete example.
Once defined in
`lib/feature.rb`
, you will be able to activate a
feature for a given feature group via the
[
`feature_group` param of the features API
](
../api/features.md#set-or-create-a-feature
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment