Class: ActiveJob::QueueAdapters::SneakersAdapter::JobWrapper

Inherits:
Object
  • Object
show all
Includes:
Sneakers::Worker
Defined in:
lib/active_job/queue_adapters/sneakers_adapter.rb

Constant Summary

Constants included from Sneakers::Worker

Sneakers::Worker::Classes

Instance Attribute Summary

Attributes included from Sneakers::Worker

#id, #opts, #queue

Instance Method Summary collapse

Methods included from Sneakers::Worker

#ack!, #do_work, included, #initialize, #log_msg, #process_work, #publish, #reject!, #requeue!, #run, #stop, #worker_trace

Methods included from Sneakers::ErrorReporter

#worker_error

Methods included from Sneakers::Concerns::Metrics

included

Methods included from Sneakers::Concerns::Logging

included

Instance Method Details

#work(msg) ⇒ Object



32
33
34
35
36
# File 'lib/active_job/queue_adapters/sneakers_adapter.rb', line 32

def work(msg)
  job_data = ActiveSupport::JSON.decode(msg)
  Base.execute job_data
  ack!
end