github.com/morlay/goqcloud@v0.0.0-20181123023149-b00e0b0b9afc/clients/redis/describe_task_info.go (about) 1 package redis 2 3 import ( 4 github_com_morlay_goqcloud "github.com/morlay/goqcloud" 5 ) 6 7 // Redis查询任务结果 8 // https://cloud.tencent.com/document/api/239/30601 9 10 type DescribeTaskInfoRequest struct { 11 // 区域 12 Region string `name:"Region"` 13 // 任务ID 14 TaskId int64 `name:"TaskId"` 15 } 16 17 func (req *DescribeTaskInfoRequest) Invoke(client github_com_morlay_goqcloud.Client) (*DescribeTaskInfoResponse, error) { 18 resp := &DescribeTaskInfoResponse{} 19 err := client.Request("redis", "DescribeTaskInfo", "2018-04-12").Do(req, resp) 20 return resp, err 21 } 22 23 type DescribeTaskInfoResponse struct { 24 github_com_morlay_goqcloud.TencentCloudBaseResponse 25 // 实例的ID 26 InstanceId string `json:"InstanceId"` 27 // 任务开始时间 28 StartTime string `json:"StartTime"` 29 // 任务状态preparing:待执行,running:执行中,succeed:成功,failed:失败,error 执行出错 30 Status string `json:"Status"` 31 // 任务信息,错误时显示错误信息。执行中与成功则为空 32 TaskMessage string `json:"TaskMessage"` 33 // 任务类型 34 TaskType string `json:"TaskType"` 35 }