Home  >  Article  >  Operation and Maintenance  >  How to use DescribeTasks to query the progress of a specified asynchronous request

How to use DescribeTasks to query the progress of a specified asynchronous request

坏嘻嘻
坏嘻嘻Original
2018-09-27 16:08:051938browse

This article introduces how to use DescribeTasks to query the progress of a specified asynchronous request, and focuses on its specific steps. The content of this article is compact, and I hope everyone can gain something.

DescribeTasks

Request Parameters

How to use DescribeTasks to query the progress of a specified asynchronous request

Return Parameters

How to use DescribeTasks to query the progress of a specified asynchronous request

##Example

Request Example

https://ecs.aliyuncs.com/?Action=DescribeTasks
&RegionId=cn-hangzhou
&<公共请求参数>

Return example

XML format

<DescribeTasksResponse>
  <PageNumber>1</PageNumber>
  <TotalCount>2</TotalCount>
  <PageSize>2</PageSize>
  <RegionId>cn-hangzhou</RegionId>
  <RequestId>E5C82807-5588-4661-9A96-350B206A7623</RequestId>
  <TaskSet>
    <Task>
      <CreationTime>2015-11-24T12:50Z</CreationTime>
      <FinishedTime>2015-11-24T12:50Z</FinishedTime>
      <SupportCancel>true</SupportCancel>
      <TaskAction>IMPORT_IMAGE</TaskAction>
      <TaskStatus>Finished</TaskStatus>
      <TaskId>t-23mo8zf9w</TaskId>
    </Task>
    <Task>
      <CreationTime>2015-11-23T15:10Z</CreationTime>
      <FinishedTime>2015-11-23T15:16Z</FinishedTime>
      <SupportCancel>true</SupportCancel>
      <TaskAction>IMPORT_IMAGE</TaskAction>
      <TaskStatus>Finished</TaskStatus>
      <TaskId>t-23sgu0dyj</TaskId>
    </Task>
  </TaskSet>
</DescribeTasksResponse>

JSON format

{
    "PageNumber": 1,
    "TotalCount": 2,
    "PageSize": 2,
    "RegionId": "cn-hangzhou",
    "RequestId": "F746C690-D9EA-4F87-AF31-8E1910FAB541",
    "TaskSet": {
        "Task": [
            {
                "CreationTime": "2015-11-24T12:50Z",
                "FinishedTime": "2015-11-24T12:50Z",
                "SupportCancel": true,
                "TaskAction": "ImportImage",
                "TaskStatus": "Finished",
                "TaskId": "t-23mo8zf9w"
            },
            {
                "CreationTime": "2015-11-23T15:10Z",
                "FinishedTime": "2015-11-23T15:16Z",
                "SupportCancel": true,
                "TaskAction": "ImportImage",
                "TaskStatus": "Finished",
                "TaskId": "t-23sgu0dyj"
            }
        ]
    }
}

Error codes

The following are error codes unique to this interface. For more error codes, please visit the API Error Center.

How to use DescribeTasks to query the progress of a specified asynchronous request

The above is the detailed content of How to use DescribeTasks to query the progress of a specified asynchronous request. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn