Class: SplitIoClient::Cache::Stores::LocalhostSplitStore
- Inherits:
-
Object
- Object
- SplitIoClient::Cache::Stores::LocalhostSplitStore
- Defined in:
- lib/splitclient-rb/cache/stores/localhost_split_store.rb
Instance Attribute Summary collapse
-
#splits_repository ⇒ Object
readonly
Returns the value of attribute splits_repository.
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(splits_repository, config, status_manager = nil) ⇒ LocalhostSplitStore
constructor
A new instance of LocalhostSplitStore.
Constructor Details
#initialize(splits_repository, config, status_manager = nil) ⇒ LocalhostSplitStore
Returns a new instance of LocalhostSplitStore.
10 11 12 13 14 |
# File 'lib/splitclient-rb/cache/stores/localhost_split_store.rb', line 10 def initialize(splits_repository, config, status_manager = nil) @splits_repository = splits_repository @config = config @status_manager = status_manager end |
Instance Attribute Details
#splits_repository ⇒ Object (readonly)
Returns the value of attribute splits_repository.
8 9 10 |
# File 'lib/splitclient-rb/cache/stores/localhost_split_store.rb', line 8 def splits_repository @splits_repository end |
Instance Method Details
#call ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/splitclient-rb/cache/stores/localhost_split_store.rb', line 16 def call if ENV['SPLITCLIENT_ENV'] == 'test' store_splits else splits_thread if defined?(PhusionPassenger) PhusionPassenger.on_event(:starting_worker_process) do |forked| splits_thread if forked end end end end |