Add a chatops interface for Flipper percentage of actors rollout
Currently the chatops interface for feature flags only allows percentage_of_time
rollout.
For experiments with feature rollout percentage_of_actors
a way to rollout device-independent features based on rollout.
https://gitlab.com/gitlab-com/chatops/-/blob/master/lib/chatops/gitlab/feature.rb
Investigation
As part of the issue "Investigate use of Percentage of Actors Flipper Feature" gitlab-org/gitlab#205206 (closed) it looks like percentage_of_actors could add value
Solution
Add an interface to chatops to enable percentage of actors rollout
[14] pry(main)> percentage = Feature.flipper.actors(42)
=> #<Flipper::Types::PercentageOfActors:0x00007f895738d4d8 @value=42>
[15] pry(main)> Feature.flipper[:discover_security].enable(percentage)
=> true
gitlabhq_development=# select * from feature_gates where feature_key = 'discover_security';
id | feature_key | key | value | created_at | updated_at
----+-------------------+----------------------+-------+---------------------------+---------------------------
5 | discover_security | percentage_of_actors | 42 | 2020-02-12 10:43:09.68394 | 2020-02-12 10:43:09.68394
(1 row)
Further
- To be used in the experiment gitlab-org/gitlab!24449 (merged)