Apache Hive : WebHCat Reference JobInfo

Last updated: December 12, 2024

Apache Hive : WebHCat Reference JobInfo

Description

Check the status of a job and get related job information given its job ID. Substitute “:jobid” with the job ID received when the job was created.

Version: Deprecated in 0.12.0

GET queue/:jobid is deprecated starting in Hive release 0.12.0. Users are encouraged to use GET jobs/:jobid instead. (See HIVE-4443.)
GET queue/:jobid is equivalent to GET jobs/:jobid – check [GET jobs/:jobid](https://hive.apache.org/docs/latest/webhcat/webhcat-reference-job/) for documentation.

Version: Obsolete in 0.14.0

GET queue/:jobid will be removed in Hive release 0.14.0. (See HIVE-6432.)
Use [GET jobs/:jobid](https://hive.apache.org/docs/latest/webhcat/webhcat-reference-job/) instead.

URL

http://www.myserver.com/templeton/v1/queue/:jobid

Parameters

NameDescriptionRequired?Default
:jobidThe job ID to check. This is the ID received when the job was created.RequiredNone

The standard parameters are also supported.

Results

NameDescription
statusA JSON object containing the job status information. See the Hadoop documentation (Class JobStatus) for more information.
profileA JSON object containing the job profile information. WebHCat passes along the information in the JobProfile object, which is subject to change from one Hadoop version to another. See the Hadoop documentation (API docs) for org.apache.hadoop.mapred.JobProfile for more information.
idThe job ID.
parentIdThe parent job ID.
percentCompleteThe job completion percentage, for example “75% complete”.
exitValueThe job’s exit value.
userUser name of the job creator.
callbackThe callback URL, if any.
completedA string representing completed status, for example “done”.

Example

Curl Command

% curl -s 'http://localhost:50111/templeton/v1/queue/job_201112212038_0004?user.name=ctdean'

JSON Output

{
 "status": {
            "startTime": 1324529476131,
            "username": "ctdean",
            "jobID": {
                      "jtIdentifier": "201112212038",
                      "id": 4
                     },
            "jobACLs": {
                       },
            "schedulingInfo": "NA",
            "failureInfo": "NA",
            "jobId": "job_201112212038_0004",
            "jobPriority": "NORMAL",
            "runState": 2,
            "jobComplete": true
           },
 "profile": {
             "url": "http://localhost:50030/jobdetails.jsp?jobid=job_201112212038_0004",
             "jobID": {
                       "jtIdentifier": "201112212038",
                        "id": 4
                      },
             "user": "ctdean",
             "queueName": "default",
             "jobFile": "hdfs://localhost:9000/tmp/hadoop-ctdean/mapred/staging/ctdean/.staging/job_201112212038_0004/job.xml",
             "jobName": "PigLatin:DefaultJobName",
             "jobId": "job_201112212038_0004"
            },
 "id": "job_201112212038_0004",
 "parentId": "job_201112212038_0003",
 "percentComplete": "100% complete",
 "exitValue": 0,
 "user": "ctdean",
 "callback": null,
 "completed": "done"
}

JSON Output (Hive 0.12.0 and later)

Version: Hive 0.12.0 and later

Starting in Hive release 0.12.0, GET queue/:jobid returns user arguments as well as status information (HIVE-5031).

{
 "status": {
            "startTime": 1324529476131,
            "username": "ctdean",
            "jobID": {
                      "jtIdentifier": "201112212038",
                      "id": 4
                     },
            "jobACLs": {
                       },
            "schedulingInfo": "NA",
            "failureInfo": "NA",
            "jobId": "job_201112212038_0004",
            "jobPriority": "NORMAL",
            "runState": 2,
            "jobComplete": true
           },
 "profile": {
             "url": "http://localhost:50030/jobdetails.jsp?jobid=job_201112212038_0004",
             "jobID": {
                       "jtIdentifier": "201112212038",
                        "id": 4
                      },
             "user": "ctdean",
             "queueName": "default",
             "jobFile": "hdfs://localhost:9000/tmp/hadoop-ctdean/mapred/staging/ctdean/.staging/job_201112212038_0004/job.xml",
             "jobName": "PigLatin:DefaultJobName",
             "jobId": "job_201112212038_0004"
            },
 "id": "job_201112212038_0004",
 "parentId": "job_201112212038_0003",
 "percentComplete": "100% complete",
 "exitValue": 0,
 "user": "ctdean",
 "callback": null,
 "completed": "done",
 "userargs" => {
                "callback"  => null,
                "define"    => [],
                "enablelog" => "false",
                "execute"   => "select a,rand(b) from mynums",
                "file"      => null,
                "files"     => [],
                "statusdir" => null,
                "user.name" => "hadoopqa",
               },
}

Navigation Links Previous: GET queue
Next: DELETE queue/:jobid

Replaced in Hive 0.12.0 by: GET jobs/:jobid