Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ITaskClient ¶
type ITaskClient interface {
CreateTask(ctx context.Context, user, group string, taskTyp uint32, taskCtx string, autoRun bool) (uint32, error)
GetTask(ctx context.Context, taskID uint32) (*model.AsyncTask, error)
GetTasks(ctx context.Context, user, group string, taskTypes []uint32, status []trans.TaskStatus, offset, limit int32) ([]*model.AsyncTask, error)
ChangeTaskGroup(ctx context.Context, taskID uint32, group string) error
SelectOneRun(ctx context.Context, taskTypes []uint32) (*model.AsyncTask, error)
SelectOneDelete(ctx context.Context, taskTypes []uint32) (*model.AsyncTask, error)
TransStatus(ctx context.Context, taskID uint32, event trans.TaskEvent) error
CheckStop(ctx context.Context, taskID uint32) (bool, error)
UpdateHeartbeat(ctx context.Context, taskID uint32) error
UpdateContext(ctx context.Context, taskID uint32, taskCtx string) error
Delete(ctx context.Context, taskID uint32) error
Clean(ctx context.Context, timeout int) error
}
ITaskClient goroutine safe
Click to show internal directories.
Click to hide internal directories.