Querying the Job Execution Plan

Function

This API is used to query a job execution plan.

URI

Request Parameters

None

Response Parameters

Table 2 Response parameters

Parameter

Mandatory

Type

Description

is_success

No

String

Whether the request is successful.

message

No

String

Message content.

execute_graph

No

Object

Response parameter for querying a job plan. For details, see Table 3.

Table 3 execute_graph parameters

Parameter

Mandatory

Type

Description

jid

No

String

ID of a Flink job.

name

No

String

Name of a Flink job.

isStoppable

No

Boolean

Whether a job can be stopped.

state

No

String

Execution status of a job. Options:

  • INITIALIZING: The job is being initialized.
  • CREATED: The job has been created.
  • RUNNING: The job is running.
  • FAILING: A failure occurs.
  • FAILED: The job has failed.
  • CANCELLING: The job is being canceled.
  • CANCELED: The job has been canceled.
  • FINISHED: The job has been completed.
  • RESTARTING: The job is being restarted.
  • SUSPENDED: The job has been suspended.
  • RECONCILING: The system is performing self-check.

start-time

No

Long

Time when a job is started.

end-time

No

Long

Time when a job is stopped.

duration

No

Long

Running duration of a job.

Example Request

None

Example Response

{
    "is_success": "true",
  "message": "Querying the job execution graph succeeds.",
    "execute_graph": {
        "jid": "4e966f43f2c90b0e1bf3188ecf55504b",
        "name": "",
        "isStoppable": false,
        "state": "RUNNING",
        "start-time": 1578904488436,
        "end-time": -1,
        "duration": 516274
    }
}

Status Codes

Table 4 Status codes

Status Code

Description

200

Querying the job execution plan succeeds.

400

The input parameter is invalid.

Error Codes

If an error occurs when this API is called, the system does not return the result similar to the preceding example, but returns an error code and error message. For details, see Error Codes.