Module: JobsDashboard::Worker

Includes:
Storage
Defined in:
lib/jobs_dashboard/worker.rb

Defined Under Namespace

Classes: Stopped

Instance Method Summary collapse

Instance Method Details

#add_job_log_line(value) ⇒ Object



17
18
19
# File 'lib/jobs_dashboard/worker.rb', line 17

def add_job_log_line(value)
  add_log_for_id(jid, value)
end

#add_job_metadata(key, value) ⇒ Object



21
22
23
# File 'lib/jobs_dashboard/worker.rb', line 21

def (key, value)
  (jid, key, value)
end

#set_job_parameter(param_name, value) ⇒ Object



10
11
12
13
14
15
# File 'lib/jobs_dashboard/worker.rb', line 10

def set_job_parameter(param_name, value)
  begin
    store_for_id(jid, { "#{param_name}": value })
  rescue ActiveModel::UnknownAttributeError
  end
end