Module: LaunchDarkly::Integrations::Redis
- Defined in:
- lib/ldclient-rb/integrations/redis.rb
Overview
Integration with [Redis](redis.io/).
Note that in order to use this integration, you must first install the ‘redis` and `connection-pool` gems.
Class Method Summary collapse
-
.default_prefix ⇒ String
Default value for the ‘prefix` option for Redis.new_feature_store.
-
.default_redis_url ⇒ String
Default value for the ‘redis_url` option for Redis.new_feature_store.
-
.new_big_segment_store(opts) ⇒ LaunchDarkly::Interfaces::BigSegmentStore
Creates a Redis-backed Big Segment store.
-
.new_feature_store(opts = {}) ⇒ LaunchDarkly::Interfaces::FeatureStore
Creates a Redis-backed persistent feature store.
Class Method Details
.default_prefix ⇒ String
Default value for the ‘prefix` option for new_feature_store.
29 30 31 |
# File 'lib/ldclient-rb/integrations/redis.rb', line 29 def self.default_prefix 'launchdarkly' end |
.default_redis_url ⇒ String
Default value for the ‘redis_url` option for new_feature_store. This points to an instance of Redis running at `localhost` with its default port.
20 21 22 |
# File 'lib/ldclient-rb/integrations/redis.rb', line 20 def self.default_redis_url 'redis://localhost:6379/0' end |
.new_big_segment_store(opts) ⇒ LaunchDarkly::Interfaces::BigSegmentStore
Creates a Redis-backed Big Segment store.
Big Segments are a specific type of segments. For more information, read the LaunchDarkly documentation: docs.launchdarkly.com/home/users/big-segments
To use this method, you must first have the ‘redis` and `connection-pool` gems installed. Then, put the object returned by this method into the `store` property of your Big Segments configuration (see `Config`).
93 94 95 |
# File 'lib/ldclient-rb/integrations/redis.rb', line 93 def self.new_big_segment_store(opts) LaunchDarkly::Impl::Integrations::Redis::RedisBigSegmentStore.new(opts) end |
.new_feature_store(opts = {}) ⇒ LaunchDarkly::Interfaces::FeatureStore
Creates a Redis-backed persistent feature store. For more details about how and why you can use a persistent feature store, see the [SDK reference guide](docs.launchdarkly.com/sdk/features/storing-data#rubys).
To use this method, you must first have the ‘redis` and `connection-pool` gems installed. Then, put the object returned by this method into the `feature_store` property of your client configuration.
61 62 63 |
# File 'lib/ldclient-rb/integrations/redis.rb', line 61 def self.new_feature_store(opts = {}) LaunchDarkly::Impl::Integrations::Redis::RedisFeatureStore.new(opts) end |