Get Task Instance Log¶
Get the log of a specified task instance.
Prerequisite¶
The user must be an EnOS user.
Request Format¶
GET https://{apigw-address}/batch-processing-service/v2.1/taskInstances
Request Parameters (URI)¶
| Name | Location (Path/Query) | Mandatory/Optional | Data Type | Description | 
|---|---|---|---|---|
| taskInstId | Query | Mandatory | String | The ID of the task instance. | 
| userId | Query | Mandatory | String | The user ID. How to get userId>> | 
| orgId | Query | Mandatory | String | The organization ID which the user belongs to. How to get orgId>> | 
| maxLength | Query | Optional | Integer | The maximum length of the queried log. | 
| action | Query | Mandatory | String | Fixed value: getLog | 
Response Parameters¶
| Name | Data Type | Description | 
|---|---|---|
| data | InstanceLog Struct | The log information struct. For more information, see InstanceLog Struct | 
InstanceLog Struct¶
Sample¶
{
  "log":"============= ninstance:t104452-201908080322 n "
}
Parameters¶
| Name | Data Type | Description | 
|---|---|---|
| log | String | The queried log information. | 
Error Code¶
| Code | Message | Description | 
|---|---|---|
| 62102 | Instance not found | The  | 
| 62109 | No log found | Internal service exception. | 
For other error codes, see Common Error Codes.
Samples¶
Request Sample¶
url: https://{apigw-address}/batch-processing-service/v2.1/taskInstances?action=getLog&taskInstId=105007-20190812013400&maxLength=&userId=yourUserId&orgId=yourOrgId
method: GET
Return Sample¶
{
  "code": 0,
  "msg": "OK",
  "data":
    {
     "log":"=========================================================================nrun  num:t1ninstance:t104452-201908080322ncmdline:techo "uuu"nsubmitter:tdb_envisionncurrent time:tThu Aug 08 03:22:38 UTC 2019n=======================================nuuun"
    }
}