Class: Sidekiq::Promise::Worker

Inherits:
MrDarcy::Promise::Celluloid
  • Object
show all
Defined in:
lib/sidekiq/promise/worker.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(worker_klass, *args) ⇒ Worker

Returns a new instance of Worker.



7
8
9
10
11
12
13
14
15
16
# File 'lib/sidekiq/promise/worker.rb', line 7

def initialize worker_klass, *args
  @worker_klass = worker_klass
  @args         = args

  this = self
  block = proc do
    this.send :subscribe
  end
  super block
end

Instance Attribute Details

#jidObject

Returns the value of attribute jid.



5
6
7
# File 'lib/sidekiq/promise/worker.rb', line 5

def jid
  @jid
end