class Gitlab::Experiment::Rollout::Random

Public Instance Methods

execute() click to toggle source

Pick a random variant if we're in the experiment group. It doesn't take into account small sample sizes but is useful and performant.

# File lib/gitlab/experiment/rollout/random.rb, line 9
def execute
  variant_names.sample
end