Class Feature::Repository::RedisRepository
In: lib/feature/repository/redis_repository.rb
Parent: Object

RedisRepository for active feature list

Example usage:

  repository = RedisRepository.new("feature_toggles")
  repository.add_active_feature(:feature_name)

‘feature_toggles’ can be whatever name you want to use for the Redis hash that will store all of your feature toggles.

Methods

Attributes

redis  [W] 

Public Class methods

Constructor

@param redis_key the key of the redis hash where all the toggles will be stored

Public Instance methods

Returns list of active features

@return [Array<Symbol>] list of active features

Add an active feature to repository

@param [Symbol] feature the feature to be added

[Validate]