You can call this operation to query node instances of a workflow.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ListFlowNodeInstance

The operation that you want to perform. Set the value to ListFlowNodeInstance.

RegionId String Yes cn-hangzhou

The ID of the region to which your project belongs.

OrderBy String No start_time

The field by which node instances are ordered.

OrderType String No desc

The method to sort node workflow instances.

PageNumber Integer No 1

The number of the page to return.

PageSize Integer No 20

The number of entries to return on each page.

ProjectId String No FP-257A173659F5****

The ID of the project.

StartTime Long No 1540796248000

The start time for querying node instances.

StatusList.N RepeatList No FAILED

The status of node instances.

Response parameters

Parameter Type Example Description
FlowNodeInstances - -

The list of node instances.

FlowNodeInstance - -

The information of a node instance.

ClusterId String C-A6C9F4F1E9E****

The ID of the cluster.

Duration Long 200

The duration for which the node instance ran.

EndTime Long 1540796248000

The time when the node instance stopped.

ExternalChildIds String application_1541559535023_34028

The IDs of applications.

ExternalId String application_1541559535023_34027

The ID of the launcher application.

ExternalInfo String empty

The external information of the node instance, such as error diagnosis information.

ExternalStatus String SUCCESS

The external status of the node instance. Valid values:

  • SUBMITTED: The node instance is submitted.
  • RUNNING: The node instance is running.
  • SUCCESS: The execution of the node instance succeeded.
  • FAIL: The execution of the node instance failed.
  • KILL_FAIL: The termination of the node instance failed.
  • KILL_SUCCESS: The termination of the node instance succeeded.
ExternalSubId String container_1541559535023_34027_01_000001

The ID of the launcher container.

FailAct String STOP

The action to take if the node instance fails. Valid values:

  • STOP: stops the workflow instance.
  • CONTINUE: skips the node instance.
FlowId String F-35683D0E45734E34

The ID of the workflow.

FlowInstanceId String FI-7CAF9709CD328EBE

The ID of the workflow instance.

GmtCreate Long 1540796236000

The creation time of the workflow.

GmtModified Long 1540796247000

The modification time of the workflow.

HostName String emr-header-1.cluster-12345

The name of the host on which the node instance runs. The host can be a master host or a gateway host. The format of the hostname is emr-header-1.cluster-12345. You can run the hostname command to view the value of this parameter.

Id String FNI-9D14A7CCF2687B84

The ID of the node instance.

JobId String FJ-A23BD131A862F184

The ID of the job.

JobName String myJob

The name of the job.

JobParams String ls -l

The content of the job.

JobType String HIVE_SQL

The type of the job.

MaxRetry String 0

The maximum number of retries of running the node instance if a failure occurs.

NodeName String node

The name of the node.

Pending Boolean false

Indicates whether the execution of the node instance ended.

ProjectId String FP-7A1018ADE917****

The ID of the project.

Retries Integer 0

The number of retries of running the node instance.

RetryInterval String 200

The interval between successive retries of running the node instance.

StartTime Long 1540796237000

The start time of the execution of the node instance.

Status String OK

The status of the node instance. Valid values:

  • PREP: The node instance is being prepared.
  • SUBMITTING: The node instance is being submitted.
  • RUNNING: The node instance is running.
  • DONE: The execution of the node instance completed.
  • OK: The execution of the node instance succeeded.
  • FAILED: The execution of the node instance failed.
  • KILLED: The node instance is terminated.
  • KILL_FAILED: The termination of the node instance failed.
  • START_RETRY: The node instance is restarting.
Type String JOB

The type of the node. Valid values:

PageNumber Integer 1

The page number of the returned page.

PageSize Integer 20

The number of entries returned per page.

RequestId String 83B256D4-4E95-454B-AD08-799DF31D5556

The ID of the request.

Total Integer 12

The total number of entries returned.

Examples

Sample requests


http(s)://[Endpoint]/? Action=ListFlowNodeInstance
&RegionId=cn-hangzhou
&<Common request parameters>

Sample success responses

XML format

<ListFlowNodeInstanceResponse>
  <PageSize>10</PageSize>
	  <RequestId>BCF52B64-007F-4883-BAEA-0499106D07C2</RequestId>
	  <PageNumber>1</PageNumber>
	  <Total>1</Total>
	  <FlowNodeInstances>
		    <FlowNodeInstance>
			      <FailAct>STOP</FailAct>
			      <Status>OK</Status>
			      <EndTime>1542957514000</EndTime>
			      <ClusterId>C-A6C9F4F1E9EC****</ClusterId>
			      <ExternalId>application_1542955685866_0003</ExternalId>
			      <pending>false</pending>
			      <JobName>success</JobName>
			      <GmtModified>1542957514000</GmtModified>
			      <StartTime>1542957499000</StartTime>
			      <ProjectId>FP-17AB3389E1AD9A34</ProjectId>
			      <MaxRetry>0</MaxRetry>
			      <ParamConf>{"cyctime":"2018-11-23 15:18:19"}</ParamConf>
			      <ExternalStatus>SUCCESS</ExternalStatus>
			      <GmtCreate>1542957499000</GmtCreate>
			      <JobType>SHELL</JobType>
			      <ExternalInfo></ExternalInfo>
			      <Retries>0</Retries>
			      <RetryInterval>0</RetryInterval>
			      <Id>FJI-F4FC53D7207E4BEF</Id>
			      <HostName>emr-header-2.cluster-500160670</HostName>
			      <JobId>FJ-31BD66C7BC502815</JobId>
		    </FlowNodeInstance>
	  </FlowNodeInstances>
	</ListFlowNodeInstanceResponse>

JSON format

{
	"PageNumber":1,
	"FlowNodeInstances":{
		"FlowNodeInstance":[
			{
				"FailAct":"STOP",
				"Retries":0,
				"ExternalId":"application_1542955685866_0003",
				"JobName":"success",
				"GmtCreate":1542957499000,
				"GmtModified":1542957514000,
				"HostName":"emr-header-2.cluster-500160670",
				"JobType":"SHELL",
				"Status":"OK",
				"MaxRetry":0,
				"RetryInterval":0,
				"ClusterId":"C-A6C9F4F1E9EC****",
				"JobId":"FJ-31BD66C7BC502815",
				"pending":false,
				"ParamConf":"{\"cyctime\":\"2018-11-23 15:18:19\"}",
				"Id":"FJI-F4FC53D7207E4BEF",
				"EndTime":1542957514000,
				"ExternalInfo":"",
				"StartTime":1542957499000,
				"ExternalStatus":"SUCCESS",
				"ProjectId":"FP-17AB3389E1AD9A34"
			}
		]
	},
	"PageSize":10,
	"RequestId":"BCF52B64-007F-4883-BAEA-0499106D07C2",
	"Total":1
}

Error codes

For a list of error codes, visit the API Error Center.