Class: LaunchDarkly::Interfaces::DataStore::Status
- Inherits:
-
Object
- Object
- LaunchDarkly::Interfaces::DataStore::Status
- Defined in:
- lib/ldclient-rb/interfaces/data_store.rb
Instance Attribute Summary collapse
-
#available ⇒ Boolean
readonly
Returns true if the SDK believes the data store is now available.
-
#stale ⇒ Boolean
readonly
Returns true if the store may be out of date due to a previous outage, so the SDK should attempt to refresh all feature flag data and rewrite it to the store.
Instance Method Summary collapse
-
#initialize(available, stale) ⇒ Status
constructor
A new instance of Status.
Constructor Details
#initialize(available, stale) ⇒ Status
Returns a new instance of Status.
84 85 86 87 |
# File 'lib/ldclient-rb/interfaces/data_store.rb', line 84 def initialize(available, stale) @available = available @stale = stale end |
Instance Attribute Details
#available ⇒ Boolean (readonly)
Returns true if the SDK believes the data store is now available.
This property is normally true. If the SDK receives an exception while trying to query or update the data store, then it sets this property to false (notifying listeners, if any) and polls the store at intervals until a query succeeds. Once it succeeds, it sets the property back to true (again notifying listeners).
98 99 100 |
# File 'lib/ldclient-rb/interfaces/data_store.rb', line 98 def available @available end |
#stale ⇒ Boolean (readonly)
Returns true if the store may be out of date due to a previous outage, so the SDK should attempt to refresh all feature flag data and rewrite it to the store.
This property is not meaningful to application code.
109 110 111 |
# File 'lib/ldclient-rb/interfaces/data_store.rb', line 109 def stale @stale end |