Sha256: 6bfbbadc63d7639a579349b716a63c1c94261ff49d811333e2a07a8d3302cf31

Contents?: true

Size: 220 Bytes

Versions: 6

Compression:

Stored size: 220 Bytes

Contents

module Lux::DelayedJob::Memory
  extend self

  @jobs = []

  def push data
    @jobs.push data

    # delayed jobs in memory are resolved asap
    Thread.new { true while pop }
  end

  def pop
    @jobs.shift
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
lux-fw-0.5.37 ./lib/lux/delayed_job/lib/memory.rb
lux-fw-0.5.36 ./lib/lux/delayed_job/lib/memory.rb
lux-fw-0.5.35 ./lib/lux/delayed_job/lib/memory.rb
lux-fw-0.5.34 ./lib/lux/delayed_job/lib/memory.rb
lux-fw-0.5.33 ./lib/lux/delayed_job/lib/memory.rb
lux-fw-0.5.32 ./lib/lux/delayed_job/lib/memory.rb