Sha256: c6df16348a06cb9c0833c3e51d3d490a8d427be712fa789ec8cbc68afb916d67
Contents?: true
Size: 334 Bytes
Versions: 60
Compression:
Stored size: 334 Bytes
Contents
class DeferredGarbageCollection DEFERRED_GC_THRESHOLD = (ENV['DEFER_GC'] || 15.0).to_f @@last_gc_run = Time.now def self.start GC.disable end def self.reconsider if Time.now - @@last_gc_run >= DEFERRED_GC_THRESHOLD GC.enable GC.start GC.disable @@last_gc_run = Time.now end end end
Version data entries
60 entries across 60 versions & 9 rubygems