Class: Gitlab::Experiment::Configuration
- Inherits:
-
Object
- Object
- Gitlab::Experiment::Configuration
- Includes:
- Singleton
- Defined in:
- lib/gitlab/experiment/configuration.rb
Class Attribute Summary collapse
-
.base_class ⇒ Object
Returns the value of attribute base_class.
-
.cache ⇒ Object
Returns the value of attribute cache.
-
.context_key_bit_length ⇒ Object
Returns the value of attribute context_key_bit_length.
-
.context_key_secret ⇒ Object
Returns the value of attribute context_key_secret.
-
.cookie_domain ⇒ Object
Returns the value of attribute cookie_domain.
-
.default_rollout ⇒ Object
Returns the value of attribute default_rollout.
-
.logger ⇒ Object
Returns the value of attribute logger.
-
.mount_at ⇒ Object
Returns the value of attribute mount_at.
-
.name_prefix ⇒ Object
Returns the value of attribute name_prefix.
-
.nested_behavior ⇒ Object
Returns the value of attribute nested_behavior.
-
.publishing_behavior ⇒ Object
Returns the value of attribute publishing_behavior.
-
.redirect_url_validator ⇒ Object
Returns the value of attribute redirect_url_validator.
-
.strict_registration ⇒ Object
Returns the value of attribute strict_registration.
-
.tracking_behavior ⇒ Object
Returns the value of attribute tracking_behavior.
Class Method Summary collapse
- .context_hash_strategy=(block) ⇒ Object deprecated Deprecated.
-
.deprecated(*args, version:, stack: 0) ⇒ Object
Internal warning helpers.
- .inclusion_resolver ⇒ Object deprecated Deprecated.
- .inclusion_resolver=(block) ⇒ Object deprecated Deprecated.
- .variant_resolver ⇒ Object deprecated Deprecated.
- .variant_resolver=(block) ⇒ Object deprecated Deprecated.
Class Attribute Details
.base_class ⇒ Object
Returns the value of attribute base_class.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def base_class @base_class end |
.cache ⇒ Object
Returns the value of attribute cache.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def cache @cache end |
.context_key_bit_length ⇒ Object
Returns the value of attribute context_key_bit_length.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def context_key_bit_length @context_key_bit_length end |
.context_key_secret ⇒ Object
Returns the value of attribute context_key_secret.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def context_key_secret @context_key_secret end |
.cookie_domain ⇒ Object
Returns the value of attribute cookie_domain.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def @cookie_domain end |
.default_rollout ⇒ Object
Returns the value of attribute default_rollout.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def default_rollout @default_rollout end |
.logger ⇒ Object
Returns the value of attribute logger.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def logger @logger end |
.mount_at ⇒ Object
Returns the value of attribute mount_at.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def mount_at @mount_at end |
.name_prefix ⇒ Object
Returns the value of attribute name_prefix.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def name_prefix @name_prefix end |
.nested_behavior ⇒ Object
Returns the value of attribute nested_behavior.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def nested_behavior @nested_behavior end |
.publishing_behavior ⇒ Object
Returns the value of attribute publishing_behavior.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def publishing_behavior @publishing_behavior end |
.redirect_url_validator ⇒ Object
Returns the value of attribute redirect_url_validator.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def redirect_url_validator @redirect_url_validator end |
.strict_registration ⇒ Object
Returns the value of attribute strict_registration.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def strict_registration @strict_registration end |
.tracking_behavior ⇒ Object
Returns the value of attribute tracking_behavior.
223 224 225 |
# File 'lib/gitlab/experiment/configuration.rb', line 223 def tracking_behavior @tracking_behavior end |
Class Method Details
.context_hash_strategy=(block) ⇒ Object
169 170 171 172 173 174 175 176 177 |
# File 'lib/gitlab/experiment/configuration.rb', line 169 def context_hash_strategy=(block) deprecated( :context_hash_strategy, 'instead use `context_key_secret` and `context_key_bit_length`', version: '0.7.0' ) @__context_hash_strategy = block end |
.deprecated(*args, version:, stack: 0) ⇒ Object
Internal warning helpers.
258 259 260 261 262 263 264 265 266 267 268 269 |
# File 'lib/gitlab/experiment/configuration.rb', line 258 def deprecated(*args, version:, stack: 0) deprecator = deprecator(version) args << args.pop.to_s.gsub('{{release}}', "#{deprecator.gem_name} #{deprecator.deprecation_horizon}") args << caller_locations(4 + stack) if args.length == 2 deprecator.warn(*args) else args[0] = "`#{args[0]}`" deprecator.deprecation_warning(*args) end end |
.inclusion_resolver ⇒ Object
213 214 215 216 217 218 219 220 221 |
# File 'lib/gitlab/experiment/configuration.rb', line 213 def inclusion_resolver deprecated( :inclusion_resolver, 'instead put this logic into custom rollout strategies', version: '0.7.0' ) @__inclusion_resolver end |
.inclusion_resolver=(block) ⇒ Object
202 203 204 205 206 207 208 209 210 |
# File 'lib/gitlab/experiment/configuration.rb', line 202 def inclusion_resolver=(block) deprecated( :inclusion_resolver, 'instead put this logic into custom rollout strategies', version: '0.7.0' ) @__inclusion_resolver = block end |
.variant_resolver ⇒ Object
180 181 182 183 184 185 186 187 188 |
# File 'lib/gitlab/experiment/configuration.rb', line 180 def variant_resolver deprecated( :variant_resolver, 'instead use `inclusion_resolver` with a block that returns a boolean', version: '0.6.5' ) @__inclusion_resolver end |
.variant_resolver=(block) ⇒ Object
191 192 193 194 195 196 197 198 199 |
# File 'lib/gitlab/experiment/configuration.rb', line 191 def variant_resolver=(block) deprecated( :variant_resolver, 'instead use `inclusion_resolver` with a block that returns a boolean', version: '0.6.5' ) @__inclusion_resolver = block end |