GetJobInstance
Retrieves the details of a task instance, including its status and progress.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
edas:ReadSchedulerxJobInstanceQuery |
get |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
Yes |
The region ID. |
cn-hangzhou |
| Namespace |
string |
Yes |
The namespace ID. You can obtain the ID from the Namespaces page in the console. |
adcfc35d-e2fe-4fe9-bbaa-20e90ffc**** |
| GroupId |
string |
Yes |
The application ID. You can obtain the ID from the Application Management page in the console. |
testSchedulerx.defaultGroup |
| JobId |
integer |
Yes |
The job ID. You can obtain the ID from the Job Management page in the console. |
92583 |
| JobInstanceId |
integer |
Yes |
The job instance ID. |
1685883418 |
| NamespaceSource |
string |
No |
The namespace source. This parameter is required only for specific third parties. |
schedulerx |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| Code |
integer |
The return code. |
200 |
| Message |
string |
The error message. |
jobId=xxx is not existed |
| RequestId |
string |
The unique ID of the request. |
4F68ABED-AC31-4412-9297-D9A8F0401108 |
| Success |
boolean |
Indicates whether the task instance details were retrieved. Valid values:
|
true |
| Data |
object |
The instance information. |
|
| JobInstanceDetail |
object |
The detailed information about the task instance. |
|
| Status |
integer |
The instance status. Valid values:
Corresponding enum class: com.alibaba.schedulerx.common.domain.InstanceStatus. |
4 |
| Progress |
string |
The progress details of the instance. |
{"taskProgress":[{"name":"MAP_TASK_ROOT","total":1,"pulled":1,"running":0,"success":0,"failed":0}],"workerProgress":[{"workerAddr":"11.122.241.245:34865","total":1,"pulled":1,"running":0,"success":0,"failed":0}]} |
| Result |
string |
The execution result of the instance. |
{'TotalSize': 31, 'CurrentPage': 5, 'PageSize': 10} |
| InstanceId |
integer |
The instance ID. |
1189853849 |
| TimeType |
integer |
The scheduling time type of the instance. Valid values:
Corresponding enum class: com.alibaba.schedulerx.common.domain.TimeType. |
1 |
| TriggerType |
integer |
The trigger type. Valid values:
Corresponding enum class: com.alibaba.schedulerx.common.domain.TriggerType. |
1 |
| EndTime |
string |
The end time of the job execution. The time is in the yyyy-MM-dd HH:mm:ss format. |
2020-07-27 11:52:10 |
| StartTime |
string |
The start time of the job execution. The time is in the yyyy-MM-dd HH:mm:ss format. |
2020-07-27 11:52:10 |
| Executor |
string |
The executor. |
John Smith |
| JobId |
integer |
The job ID. |
92583 |
| ScheduleTime |
string |
The scheduled time. The time is in the yyyy-MM-dd HH:mm:ss format. |
2020-07-27 11:52:10 |
| DataTime |
string |
The data timestamp of the node. The time is in the yyyy-MM-dd HH:mm:ss format. |
2020-07-27 11:52:10 |
| WorkAddr |
string |
The IP address and port of the triggered client in the IP:port format. |
192.168.0.0:16 |
| Parameters |
string |
The parameter information of the job instance. |
{\"alertId\":11111} |
| JobName |
string |
The job name. |
ManualJob |
| TraceId |
string |
The trace ID. You can use this ID to precisely query invocation information. |
210e845016596663430048015d0a2c |
Examples
Success response
JSON format
{
"Code": 200,
"Message": "jobId=xxx is not existed",
"RequestId": "4F68ABED-AC31-4412-9297-D9A8F0401108",
"Success": true,
"Data": {
"JobInstanceDetail": {
"Status": 4,
"Progress": "{\"taskProgress\":[{\"name\":\"MAP_TASK_ROOT\",\"total\":1,\"pulled\":1,\"running\":0,\"success\":0,\"failed\":0}],\"workerProgress\":[{\"workerAddr\":\"11.122.241.245:34865\",\"total\":1,\"pulled\":1,\"running\":0,\"success\":0,\"failed\":0}]}",
"Result": "{'TotalSize': 31, 'CurrentPage': 5, 'PageSize': 10}",
"InstanceId": 1189853849,
"TimeType": 1,
"TriggerType": 1,
"EndTime": "2020-07-27 11:52:10",
"StartTime": "2020-07-27 11:52:10",
"Executor": "John Smith",
"JobId": 92583,
"ScheduleTime": "2020-07-27 11:52:10",
"DataTime": "2020-07-27 11:52:10",
"WorkAddr": "192.168.0.0:16",
"Parameters": "{\\\"alertId\\\":11111}",
"JobName": "ManualJob",
"TraceId": "210e845016596663430048015d0a2c"
}
}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.