You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by kun yan <ya...@gmail.com> on 2014/02/10 10:47:39 UTC

get the Hive job status

By jdbc run hive, how to get the Hive job status

Now I'm currently using the following method
               Configuration conf = new Configuration();
JobConf job = new JobConf(conf);
JobClient jc = new JobClient(job);
// 获取集群状态
// ClusterStatus cs = jc.getClusterStatus();
JobStatus[] jobStatus = jc.getAllJobs();
for (JobStatus js : jobStatus) {
System.out.println(js.getRunState());
}

but jobStatus is always null,when the hive job is running ,jobStatus always
null !
Who can provide some help or advice for me?
-- 

In the Hadoop world, I am just a novice, explore the entire Hadoop
ecosystem, I hope one day I can contribute their own code

YanBit
yankunhadoop@gmail.com