Retrieves job snapshot data at a specific point in time.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
odps:ListJobSnapshotInfos |
list |
*All Resource
|
None | None |
Request syntax
POST /api/v1/jobs/snapshot HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| tenantId |
string |
No |
The tenant ID. To view the tenant ID, log on to the MaxCompute console. In the navigation pane on the left, choose Tenant Management > Tenant Properties. |
478403690625249 |
| region |
string |
No |
The region ID. |
cn-chengdu |
| orderColumn |
string |
No |
The column to sort by. Valid values:
|
cpuUsage |
| ascOrder |
boolean |
No |
Specifies whether to sort the results in ascending order. |
true |
| pageNumber |
integer |
No |
The page number. |
1 |
| pageSize |
integer |
No |
The number of entries per page. |
10 |
| body |
object |
No |
The request body. |
|
| from |
integer |
No |
The start UNIX timestamp. Note
This parameter is invalid. The end timestamp is the point in time for the snapshot that you want to view. |
1706840714 |
| to |
integer |
Yes |
The end UNIX timestamp. |
1706840714 |
| quotaNickname |
string |
No |
The nickname of the computing quota that the job uses. |
quota_A |
| projectList |
array |
No |
The project name. |
|
|
string |
No |
The project name. |
projectA |
|
| typeList |
array |
No |
The job type. |
|
|
string |
No |
The job type. |
SQL |
|
| jobOwnerList |
array |
No |
The job owner. |
|
|
string |
No |
The job owner. |
ALIYUN$7632***@aliyun.com |
|
| signatureList |
array |
No |
The signature of the SQL job. |
|
|
string |
No |
The signature of the SQL job. |
signatureabc |
|
| extNodeIdList |
array |
No |
The upstream node ID. |
|
|
string |
No |
The upstream node ID. |
76358164 |
|
| instanceIdList |
array |
No |
The job instance ID. |
|
|
string |
No |
The job instance ID. |
20241028****jkl |
|
| statusList |
array |
No |
The job status. |
|
|
string |
No |
The job status. |
running |
|
| priorityList |
array |
No |
The job priority. |
|
|
integer |
No |
The job priority. |
9 |
|
| sortByList |
array |
No |
The fields for multi-column sorting. |
|
|
string |
No |
A field for multi-column sorting. |
cuUsage |
|
| sortOrderList |
array |
No |
The sort orders for multi-column sorting. |
|
|
string |
No |
A sort order for multi-column sorting. |
desc |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
PopResult |
||
| requestId |
string |
The request ID. |
0b87b7e716665825896565060e87a4 |
| httpCode |
integer |
The HTTP status code.
|
200 |
| errorCode |
string |
The error code. |
OBJECT_NOT_EXIST |
| errorMsg |
string |
The error message. |
异常信息 |
| data |
object |
The returned data. |
|
| jobInfoList |
array<object> |
The list of job snapshots. |
|
|
object |
The job snapshot information. |
||
| tenantId |
string |
The tenant ID. |
213065738244354 |
| region |
string |
The region ID. |
cn-chengdu |
| instanceId |
string |
The job ID. |
20241028****jkl |
| jobOwner |
string |
The job owner. |
ALIYUN$7632***@aliyun.com |
| project |
string |
The project name. |
projectA |
| jobType |
string |
The job type. |
SQL |
| priority |
integer |
The job priority. |
9 |
| status |
string |
The job status. Note
The status of a snapshot job can only be `running`. |
running |
| quotaNickname |
string |
The nickname of the computing quota that the job uses. |
quota_A |
| quotaType |
string |
The quota type. |
subscription |
| cpuUsage |
integer |
The CPU usage of the job at the snapshot time. Unit: cores. |
100 |
| memoryUsage |
integer |
The memory usage of the job at the snapshot time. Unit: MB. |
409600 |
| maxCpuPct |
number |
This parameter is not used. |
-1 |
| minCpuPct |
number |
The CPU usage percentage of a subscription job at the snapshot time. This value is calculated by dividing the CPU usage by the sum of the reserved CPU guarantee and the elastic reserved CPU. This parameter is not available for pay-as-you-go jobs. |
0.6 |
| maxMemoryPct |
number |
This parameter is not used. |
-1 |
| minMemoryPct |
number |
The memory usage percentage of a subscription job at the observation time. This value is calculated by dividing the memory usage by the sum of the reserved memory guarantee and the elastic reserved memory. This parameter is not available for pay-as-you-go jobs. |
0.6 |
| submittedAtTime |
integer |
The time when the job was submitted. |
1736821785 |
| waitingTime |
integer |
The waiting duration, in seconds. This is the duration from when the job was submitted to when it started running. If the job has not started, this is the duration from the submission time to the snapshot time. |
20 |
| runningAtTime |
integer |
The time when the job started running. Note
The time when the job acquired its first computing resource. |
1736821805 |
| runningTime |
integer |
The runtime duration, in seconds. This is the duration from when the job started running to the snapshot time. If the job has not started, this parameter is empty. |
43 |
| snapshotTime |
integer |
The snapshot time. |
1736821848 |
| totalTime |
integer |
The total duration, in seconds. This is the duration from when the job was submitted to the snapshot time. |
63 |
| signature |
string |
The signature of the SQL job. |
signatureabc |
| extPlantFrom |
string |
The upstream platform. |
Dataworks |
| extNodeId |
string |
The upstream node ID. |
76358164 |
| extNodeOnDuty |
string |
The account ID of the task owner. |
duty_2 |
| cpuRequest |
integer |
The amount of CPU cores requested by the job at the snapshot time. |
200 |
| memoryRequest |
integer |
The amount of memory requested by the job at the snapshot time, in MB. |
409600 |
| cpuUsageToRequestRatio |
number |
The CPU fulfillment ratio of the job at the snapshot time. This is calculated by dividing the CPU usage by the CPU request. |
0.5 |
| memoryUsageToRequestRatio |
number |
The memory fulfillment ratio of the job at the snapshot time. This is calculated by dividing the memory usage by the memory request. |
1 |
| extPlatformId |
string |
||
| totalCount |
integer |
The total number of entries returned. |
123 |
| pageNumber |
integer |
The page number. |
1 |
| pageSize |
integer |
The number of entries per page. |
10 |
Examples
Success response
JSON format
{
"requestId": "0b87b7e716665825896565060e87a4",
"httpCode": 200,
"errorCode": "OBJECT_NOT_EXIST",
"errorMsg": "异常信息",
"data": {
"jobInfoList": [
{
"tenantId": "213065738244354",
"region": "cn-chengdu",
"instanceId": "20241028****jkl",
"jobOwner": "ALIYUN$7632***@aliyun.com",
"project": "projectA",
"jobType": "SQL",
"priority": 9,
"status": "running",
"quotaNickname": "quota_A",
"quotaType": "subscription",
"cpuUsage": 100,
"memoryUsage": 409600,
"maxCpuPct": -1,
"minCpuPct": 0.6,
"maxMemoryPct": -1,
"minMemoryPct": 0.6,
"submittedAtTime": 1736821785,
"waitingTime": 20,
"runningAtTime": 1736821805,
"runningTime": 43,
"snapshotTime": 1736821848,
"totalTime": 63,
"signature": "signatureabc",
"extPlantFrom": "Dataworks",
"extNodeId": "76358164",
"extNodeOnDuty": "duty_2",
"cpuRequest": 200,
"memoryRequest": 409600,
"cpuUsageToRequestRatio": 0.5,
"memoryUsageToRequestRatio": 1,
"extPlatformId": ""
}
],
"totalCount": 123,
"pageNumber": 1,
"pageSize": 10
}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.