Module: JobStatus::Tracker
- Defined in:
- lib/job_status/tracker.rb
Overview
Tracking routines used by the callbacks
Class Method Summary collapse
-
.enqueue(job_id) ⇒ Object
Sets the initial queued worker status and sets the expiry.
-
.remove(job_id) ⇒ Object
Removes any information from the cache for the given job_id.
-
.update(job_id, status) ⇒ Object
Stores the current status within the storage.
Class Method Details
.enqueue(job_id) ⇒ Object
Sets the initial queued worker status and sets the expiry
11 12 13 |
# File 'lib/job_status/tracker.rb', line 11 def self.enqueue(job_id) JobStatus.store.write(job_id, {status: :queued, at: 0, total: 100}, expires_in: 259200) end |