Documentation
¶
Index ¶
- Variables
- type Inspector
- type Manager
- func (m *Manager) Close() error
- func (m *Manager) EnqueueJSON(taskType string, payload any) (string, error)
- func (m *Manager) EnqueueJSONCtx(ctx context.Context, taskType string, payload any) (string, error)
- func (m *Manager) EnqueueJSONCtxWithPolicy(ctx context.Context, taskType string, payload any, policy tasks.EnqueuePolicy) (string, error)
- func (m *Manager) EnqueueJSONWithPolicy(taskType string, payload any, policy tasks.EnqueuePolicy) (string, error)
- func (m *Manager) HandleFunc(taskType string, handler tasks.HandlerFunc) error
- func (m *Manager) Retried() int64
- func (m *Manager) Run(ctx context.Context) error
- type Scheduler
- type SchedulerConfig
- type Task
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrTaskTypeRequired = errors.New("memoryprovider: task type cannot be empty") ErrNilHandler = errors.New("memoryprovider: handler cannot be nil") // ErrUnsupportedQueue reports an EnqueuePolicy.Queue this provider has // no queue for: it runs a single in-process queue. Naming another one // used to be accepted and ignored (NU-12). ErrUnsupportedQueue = errors.New("memoryprovider: named queues are not supported (only the default queue exists)") )
View Source
var (
ErrNilScheduler = errors.New("memoryprovider: scheduler is nil")
)
Functions ¶
This section is empty.
Types ¶
type Inspector ¶
type Inspector struct {
// contains filtered or unexported fields
}
func NewInspector ¶
func (*Inspector) InspectRuntime ¶
func (i *Inspector) InspectRuntime() tasks.RuntimeSnapshot
func (*Inspector) OperateQueue ¶
func (i *Inspector) OperateQueue(queue, action string) (tasks.QueueActionResult, error)
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func (*Manager) EnqueueJSON ¶
func (*Manager) EnqueueJSONCtx ¶
func (*Manager) EnqueueJSONCtxWithPolicy ¶
func (*Manager) EnqueueJSONWithPolicy ¶
func (*Manager) HandleFunc ¶
func (m *Manager) HandleFunc(taskType string, handler tasks.HandlerFunc) error
type Scheduler ¶
type Scheduler struct {
// contains filtered or unexported fields
}
func NewScheduler ¶
func NewScheduler(cfg SchedulerConfig) (*Scheduler, error)
func (*Scheduler) RegisterJSON ¶
func (*Scheduler) Unregister ¶
type SchedulerConfig ¶
Click to show internal directories.
Click to hide internal directories.