abstract class Mosquito::Backend

Direct Known Subclasses

Defined in:

mosquito/backend.cr

Constant Summary

KEY_PREFIX = {"mosquito"}
QUEUES = ["waiting", "scheduled", "pending", "dead"] of ::String

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(name : String | Symbol) #

Class Method Detail

def self.build_key(*parts) #

def self.named(name) #

def self.search_queues #

Instance Method Detail

def build_key(*parts) #

def dead_q #

def delete(key : String, in ttl = 0) : Nil #

abstract def dequeue : JobRun | Nil #

abstract def deschedule : Array(JobRun) #

abstract def dump_dead_q : Array(String) #

abstract def dump_pending_q : Array(String) #

abstract def dump_scheduled_q : Array(String) #

abstract def dump_waiting_q : Array(String) #

abstract def enqueue(job_run : JobRun) : JobRun #

from queue.cr


def expires_in(key : String) : Int64 #

abstract def finish(job_run : JobRun) #

abstract def flush : Nil #

def pending_q #

def retrieve(key : String) : Hash(String, String) #

abstract def schedule(job_run : JobRun, at scheduled_time : Time) : JobRun #

abstract def scheduled_job_run_time(job_run : JobRun) : String | Nil #

def scheduled_q #

abstract def size(include_dead : Bool = true) : Int64 #

def store(key : String, value : Hash(String, String)) : Nil #

abstract def terminate(job_run : JobRun) #

def waiting_q #