Versions in this module Expand all Collapse all v1 v1.0.0 Dec 21, 2017 Changes in this version + const ResultStatusFailure + const ResultStatusInternalFailure + const ResultStatusPermanentFailure + const ResultStatusSuccess + type ConnectionClosedError struct + func (e *ConnectionClosedError) Error() string + type FailedJob struct + Category string + CreatedAt time.Time + FailCount uint + FailedAt time.Time + ID uint64 + JobID uint64 + Payload json.RawMessage + Result *Result + URL string + type FailedJobs struct + FailedJobs []FailedJob + NextCursor string + type FailureLog interface + Add func(failed Job, result *Result) error + Delete func(failureID uint64) error + Find func(failureID uint64) (*FailedJob, error) + FindAll func(limit uint, cursor string) (*FailedJobs, error) + FindAllRecentFailures func(limit uint, cursor string) (*FailedJobs, error) + type HasFailureLog interface + FailureLog func() FailureLog + type HasInspector interface + Inspector func() Inspector + type HasNodeInfo interface + Node func() (*Node, error) + type Impl interface + Delete func(job Job) + IsActive func() bool + Pop func(limit uint) ([]Job, error) + Push func(job IncomingJob) (Job, error) + Start func() + Stop func() <-chan struct{} + Update func(job Job, next NextInfo) + type InactiveError struct + func (e *InactiveError) Error() string + type IncomingJob interface + Category func() string + NextDelay func() uint64 + Payload func() string + RetryCount func() uint + RetryDelay func() uint + Timeout func() uint + URL func() string + type InspectedJob struct + Category string + CreatedAt time.Time + FailCount uint + ID uint64 + MaxRetries uint + NextTry time.Time + Payload json.RawMessage + RetryDelay uint + Status string + Timeout uint + URL string + type InspectedJobs struct + Jobs []InspectedJob + NextCursor string + type Inspector interface + Delete func(jobID uint64) error + Find func(jobID uint64) (*InspectedJob, error) + FindAllDeferred func(limit uint, cursor string) (*InspectedJobs, error) + FindAllGrabbed func(limit uint, cursor string) (*InspectedJobs, error) + FindAllWaiting func(limit uint, cursor string) (*InspectedJobs, error) + type Job interface + FailCount func() uint + Payload func() string + RetryCount func() uint + RetryDelay func() uint + Timeout func() uint + ToLoggable func() logger.LoggableJob + URL func() string + type JobQueue interface + Complete func(job Job, res *Result) + FailureLog func() (FailureLog, bool) + Inspector func() (Inspector, bool) + IsActive func() bool + Name func() string + Node func() (*Node, error) + Pop func(limit uint) ([]Job, error) + Push func(job IncomingJob) (uint64, error) + Stats func() *Stats + Stop func() <-chan struct{} + func Start(definition *model.Queue, q Impl) JobQueue + type NextInfo interface + FailCount func() uint + NextDelay func() uint64 + RetryCount func() uint + type Node struct + Host string + ID string + type Result struct + Code int + Message string + Status string + func (rslt *Result) IsFailure() bool + func (rslt *Result) IsFinished() bool + func (rslt *Result) IsValid() bool + type Stats struct + PopsPerSecond int64 + PushesPerSecond int64 + TotalCompletes int64 + TotalElapsed int64 + TotalFailures int64 + TotalPops int64 + TotalPushes int64 + TotalSuccesses int64