I don't know if we have Java API for this.

But if you dig deeper on consumer offset checker it just makes query from 
Zookeeper.

Kafka.utils.ZkUtils does all the calls for reading data from Zookeeper.

-----Original Message-----
From: Harshvardhan Chauhan [mailto:[email protected]] 
Sent: Friday, March 28, 2014 2:44 PM
To: [email protected]
Subject: Re: Java API to monitor Consumer Offset and Lag

I am aware of that but I should have put my question more accurately.

I want to automate monitoring consumer offset and lag and wanted to know if 
there is a Java API for that.
The ConsumerOffsetChecker has a main method and prints the information on 
console, I want to capture the data and push it to a monitoring server in a 
cleaner way other than capturing ConsumerOffsetChecker console output.

Regards,
Harsh


On Fri, Mar 28, 2014 at 1:41 PM, Seshadri, Balaji
<[email protected]>wrote:

> This is Scala API should be possible to call it from Groovy.
>
> -----Original Message-----
> From: Seshadri, Balaji [mailto:[email protected]]
> Sent: Friday, March 28, 2014 1:57 PM
> To: '[email protected]'
> Subject: RE: Java API to monitor Consumer Offset and Lag
>
> kafka.tools.ConsumerOffsetChecker
>
> -----Original Message-----
> From: Harshvardhan Chauhan [mailto:[email protected]]
> Sent: Friday, March 28, 2014 12:54 PM
> To: [email protected]
> Subject: Java API to monitor Consumer Offset and Lag
>
> Hi,
>
> I am trying to write a groovy script to get consumer offsets and lag 
> for our kafka cluster.
> Is there a Java API to get this information ?
>
> Thanks & regards,
> --
> *Harshvardhan Chauhan*  |  Big Data Engineer
> *GumGum* <http://www.gumgum.com/>  |  *Ads that stick*
> 310-260-9666  |  [email protected]
>



--
*Harshvardhan Chauhan*  |  Big Data Engineer
*GumGum* <http://www.gumgum.com/>  |  *Ads that stick*
310-260-9666  |  [email protected]

Reply via email to