Verk v1.0.1 Verk.Queue
This module interacts with a queue
Link to this section Summary
Functions
Clears the queue
Clears the queue, raising if there’s an error
Counts how many jobs are enqueued on a queue
Counts how many jobs are enqueued on a queue, raising if there’s an error
Deletes the job from the queue
Delete job from the queue, raising if there’s an error
Lists enqueued jobs from start to stop
Lists enqueued jobs from start to stop, raising if there’s an error
Link to this section Functions
Clears the queue
It will return {:ok, true} if the queue was cleared and {:ok, false} otherwise
An error tuple may be returned if Redis failed
Clears the queue, raising if there’s an error
It will return true if the queue was cleared and false otherwise
Counts how many jobs are enqueued on a queue
Counts how many jobs are enqueued on a queue, raising if there’s an error
delete_job(binary, %Verk.Job{args: term, class: term, enqueued_at: term, error_backtrace: term, error_message: term, failed_at: term, finished_at: term, jid: term, max_retry_count: term, original_json: term, queue: term, retried_at: term, retry_count: term} | binary) ::
{:ok, boolean} |
{:error, Redix.Error.t}
Deletes the job from the queue
It returns {:ok, true} if the job was found and deleted
Otherwise it returns {:ok, false}
An error tuple may be returned if Redis failed
delete_job!(binary, %Verk.Job{args: term, class: term, enqueued_at: term, error_backtrace: term, error_message: term, failed_at: term, finished_at: term, jid: term, max_retry_count: term, original_json: term, queue: term, retried_at: term, retry_count: term} | binary) :: boolean
Delete job from the queue, raising if there’s an error
It returns true if the job was found and delete
Otherwise it returns false
An error will be raised if Redis failed
range(binary, integer, integer) ::
{:ok, [Verk.Job.T]} |
{:error, Redix.Error.t}
Lists enqueued jobs from start to stop
range!(binary, integer, integer) :: [Verk.Job.T]
Lists enqueued jobs from start to stop, raising if there’s an error