Method: Fluent::Counter::MutexHash#initialize

Defined in:
lib/fluent/counter/mutex_hash.rb

#initialize(data_store) ⇒ MutexHash

Returns a new instance of MutexHash.



22
23
24
25
26
27
28
# File 'lib/fluent/counter/mutex_hash.rb', line 22

def initialize(data_store)
  @mutex = Mutex.new
  @data_store = data_store
  @mutex_hash = {}
  @thread = nil
  @cleanup_thread = CleanupThread.new(@data_store, @mutex_hash, @mutex)
end