|
|
|
|
|
by JamesSwift
423 days ago
|
|
Looks good. Id suggest making your `get` wait to acquire the lock until needed. eg instead of @lock.synchronize do
entry = @store[key]
return nil unless entry
...
you can do entry = @store[key]
return nil unless entry
@lock.synchronize do
entry = @store[key]
And similarly for other codepaths |
|