Module: Dalli::PIDCache::CoreExt

Included in:
Dalli::PIDCache
Defined in:
lib/dalli/pid_cache.rb

Overview

Dalli::PIDCache::CoreExt hooks into Process to be able to reset the PID cache after fork

Instance Method Summary collapse

Instance Method Details

#_forkObject



25
26
27
28
29
# File 'lib/dalli/pid_cache.rb', line 25

def _fork
  child_pid = super
  PIDCache.update! if child_pid.zero?
  child_pid
end