Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BatchTask ¶
type BatchTask interface { CreateTask(ctx context.Context, req *CreateTaskReq) (*CreateTaskResp, error) GetList(ctx context.Context, req *GetListReq) (*GetListResp, error) GetByID(ctx context.Context, req *GetByIDReq) (*GetByIDResp, error) Subscribe(ctx context.Context, req *SubscribeReq) (*SubscribeResp, error) GetProcessing(ctx context.Context, req *GetProcessingReq) (*GetProcessingResp, error) Delete(ctx context.Context, req *DeleteReq) (*DeleteResp, error) Timeout(ctx context.Context) }
BatchTask BatchTask
func NewBatchTask ¶
NewBatchTask NewBatchTask
type CreateTaskReq ¶
type CreateTaskReq struct { ID string `json:"taskID"` UserID string `json:"userID"` UserName string `json:"userName"` DepID string `json:"depID"` Value logic.M `json:"value" binding:"required"` Addr string `json:"addr"` Opt string `json:"opt"` Size int `json:"size"` Command string `json:"command" binding:"required"` Title string `json:"title"` }
CreateTaskReq CreateTaskReq
type CreateTaskResp ¶
type CreateTaskResp struct {
TaskID string `json:"taskID"`
}
CreateTaskResp CreateTaskResp
type DaprEvent ¶
type DaprEvent struct { Topic string `json:"topic"` Pubsubname string `json:"pubsubname"` Traceid string `json:"traceid"` ID string `json:"id"` Datacontenttype string `json:"datacontenttype"` Data *CreateTaskReq `json:"data"` Type string `json:"type"` Specversion string `json:"specversion"` Source string `json:"source"` }
DaprEvent DaprEvent
type GetByIDResp ¶
type GetByIDResp struct { ID string `json:"id"` Title string `json:"title"` Status models.TaskStatus `json:"status"` Result logic.M `json:"result"` Command string `json:"command"` Ratio float64 `json:"ratio"` Value logic.M `json:"value"` CreatedAt int64 `json:"createdAt"` FinishAt int64 `json:"finishAt"` }
GetByIDResp GetByIDResp
type GetListReq ¶
type GetListReq struct { UserID string `json:"userID"` Status models.TaskStatus `json:"status"` Page int `json:"page"` Limit int `json:"limit"` Types string `json:"types"` }
GetListReq GetListReq
type GetListResp ¶
type GetListResp struct { List []*TaskListVo `json:"list"` Total int64 `json:"total"` }
GetListResp GetListResp
type GetProcessingReq ¶
GetProcessingReq GetProcessingReq
type GetProcessingResp ¶
type GetProcessingResp struct {
Total int64 `json:"total"`
}
GetProcessingResp GetProcessingResp
type SubscribeReq ¶
type SubscribeReq struct { UserID string `json:"userID"` UUID string `json:"uuid"` Topic string `json:"topic" binding:"required"` Key string `json:"key" binding:"required"` }
SubscribeReq SubscribeReq
type SubscribeResp ¶
type SubscribeResp struct { IsFinish bool `json:"isFinish"` Status models.TaskStatus `json:"status"` }
SubscribeResp SubscribeResp
type TaskListVo ¶
type TaskListVo struct { ID string `json:"id"` Title string `json:"title"` Status models.TaskStatus `json:"status"` Result logic.M `json:"result"` Command string `json:"command"` Ratio float64 `json:"ratio"` Value logic.M `json:"value"` CreatedAt int64 `json:"createdAt"` FinishAt int64 `json:"finishAt"` }
TaskListVo TaskListVo
Click to show internal directories.
Click to hide internal directories.