Reply
New Contributor
Posts: 4
Registered: ‎11-26-2013

impala query history

If I go to Cloudera Manager, I can click on Impala, then Queries to see the impala query history.

 

I would like to extract all available query history and dump it into my own database for analysis. Is the query history stored in CM database (we use mysql)?

Posts: 1,903
Kudos: 435
Solutions: 305
Registered: ‎07-31-2013

Re: impala query history

CM DB is not for direct use as it is not a user/dev facing element (no compatibility guarantees).

CM instead offers an API that can be used for almost any/every action you otherwise do over the UI: http://cloudera.github.io/cm_api/

For Impala queries, use this API end-point: http://cloudera.github.io/cm_api/apidocs/v11/path__clusters_-clusterName-_services_-serviceName-_imp... You can get the same data that the UI shows (both are powered by the same source)
New Contributor
Posts: 4
Registered: ‎11-26-2013

Re: impala query history

Thanks..actually I've already gone that route. There's a hard limit of 1000 queries being returned, so I had to schedule the job ask for query history within a 1 hour period so as not to exceed that 1000 limit.

 

Thanks!

New Contributor
Posts: 5
Registered: ‎05-26-2017

Re: impala query history

tsusanto, did you get a solution for this ? Querying the Database seems the only option as we see it

 

Thanks,

 

Highlighted
Cloudera Employee
Posts: 1
Registered: ‎02-15-2018

Re: impala query history

@MahendraDevu you can use the cm api's paging feature using the offset parameter to flip through the queries.

 

Thanks,

Shashank