Documentation ¶
Index ¶
- func BatchEnqueue(ctx context.Context, topic string, messages []string, args ...interface{}) (isOk bool, err error)
- func BatchEnqueueWithTask(ctx context.Context, topic string, tasks []work.Task, args ...interface{}) (isOk bool, err error)
- func Enqueue(ctx context.Context, topic string, message string, args ...interface{}) (isOk bool, err error)
- func EnqueueWithTask(ctx context.Context, topic string, task work.Task, args ...interface{}) (isOk bool, err error)
- func GetJob() *work.Job
- func SetJob(job *work.Job)
- func SetJobRegister(r func(*work.Job))
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BatchEnqueue ¶
func BatchEnqueue(ctx context.Context, topic string, messages []string, args ...interface{}) (isOk bool, err error)
*
- 消息批量入队 -- 原始message
func BatchEnqueueWithTask ¶
func BatchEnqueueWithTask(ctx context.Context, topic string, tasks []work.Task, args ...interface{}) (isOk bool, err error)
*
- 消息批量入队 -- Task数据结构
func Enqueue ¶
func Enqueue(ctx context.Context, topic string, message string, args ...interface{}) (isOk bool, err error)
*
- 消息入队 -- 原始message
func EnqueueWithTask ¶
func EnqueueWithTask(ctx context.Context, topic string, task work.Task, args ...interface{}) (isOk bool, err error)
*
- 消息入队 -- Task数据结构
func SetJobRegister ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.