Querying Information About a Job

Function

This API is used to query information about a specified job in an MRS cluster.

URI

Request

Request parameters

None.

Response

Table 2 Response parameter description

Parameter

Type

Description

job_detail

Object

Job details. For details about the parameter, see Table 3.

Table 3 Job parameter description

Parameter

Type

Description

job_id

String

Job ID.

user

String

Name of the user who submits a job.

job_name

String

Job name. It contains 1 to 64 characters. Only letters, digits, hyphens (-), and underscores (_) are allowed.

job_result

String

Final result of a job.

  • FAILED: indicates that the job fails to be executed.
  • KILLED: indicates that the job is manually terminated during execution.
  • UNDEFINED: indicates that the job is being executed.
  • SUCCEEDED: indicates that the job has been successfully executed.

job_state

String

Execution status of a job.

  • FAILED: failed
  • KILLED: indicates that the job is terminated.
  • New: indicates that the job is created.
  • NEW_SAVING: indicates that the job has been created and is being saved.
  • SUBMITTED: indicates that the job is submitted.
  • ACCEPTED: indicates that the job is accepted.
  • RUNNING: indicates that the job is running.
  • FINISHED: indicates that the job is completed.

job_progress

Float

Job execution progress.

job_type

String

Type of a job.

  • MapReduce
  • SparkSubmit
  • HiveScript
  • HiveSql
  • DistCp, importing and exporting data
  • SparkScript
  • SparkSql
  • Flink

started_time

Long

Start time to run a job. Unit: ms.

submitted_time

Long

Time when a job is submitted. Unit: ms.

finished_time

Long

End time to run a job. Unit: ms.

elapsed_time

Long

Running duration of a job. Unit: ms.

arguments

Array

Running parameter. The parameter contains a maximum of 4,096 characters, excluding special characters such as ;|&>'<$, and can be left blank.

properties

Object

Configuration parameter, which is used to configure -d parameters. The parameter contains a maximum of 2,048 characters, excluding special characters such as ><|'`&!\, and can be left blank.

launcher_id

String

Launcher job ID.

app_id

String

Actual job ID.

Example

Status Code

For details about status codes, see Status Codes.