Class: Moneta::Shared
Overview
Shares a store between processes
Instance Attribute Summary
Attributes inherited from Proxy
Instance Method Summary collapse
-
#close ⇒ Object
Explicitly close the store.
-
#initialize(options = {}, &block) ⇒ Shared
constructor
A new instance of Shared.
Methods inherited from Wrapper
#clear, #create, #delete, #features, #increment, #key?, #load, #store
Methods inherited from Proxy
#clear, #create, #delete, #features, #increment, #key?, #load, #store
Methods included from Defaults
#[], #[]=, #create, #decrement, #features, #fetch, included, #increment, #key?, #supports?
Methods included from OptionSupport
#expires, #prefix, #raw, #with
Constructor Details
Instance Method Details
#close ⇒ Object
Explicitly close the store
24 25 26 27 28 29 30 31 32 33 34 |
# File 'lib/moneta/shared.rb', line 24 def close if @server @server.stop @thread.join @server = @thread = nil end if @adapter @adapter.close @adapter = nil end end |