Class: TrackingMutex

Inherits:
Mutex
  • Object
show all
Defined in:
lib/mqrpc/sizedhash.rb

Overview

A mutex which logs every enter/exit on synchronize

Instance Method Summary collapse

Instance Method Details

#synchronize(&blk) ⇒ Object



6
7
8
9
10
# File 'lib/mqrpc/sizedhash.rb', line 6

def synchronize(&blk)
  MQRPC::logger.debug "Enter synchronize #{self} @ #{caller[0]}"
  super { blk.call }
  MQRPC::logger.debug "Exit synchronize #{self} @ #{caller[0]}"
end