Help us shape the future of Go! Take the 2026 Go Developer Survey

worker

package
v1.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2026 License: Apache-2.0 Imports: 35 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultDetectInterval = time.Second * 10
)

Variables

View Source
var (
	ErrRateLimitExceeded = errors.New("rate limit exceeded")
	ErrTerminated        = errors.New("terminated")
)

Functions

This section is empty.

Types

type Options added in v0.8.0

type Options struct {
	RequeueJobBatch int
	PoolSize        int
	PoolConcurrency int

	DB                    *db.DB
	DelivererOptions      deliverer.Options
	RedisClient           *redis.Client
	CircuitBreakerManager *circuitbreaker.Manager
	EnabledDetection      bool
}

type Worker

type Worker struct {
	// contains filtered or unexported fields
}

func NewWorker

func NewWorker(opts Options, services *services.Services) *Worker

func (*Worker) Name added in v1.0.1

func (w *Worker) Name() string

func (*Worker) Start

func (w *Worker) Start() error

Start starts worker

func (*Worker) Stop

func (w *Worker) Stop(ctx context.Context) error

Stop stops worker

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL