aio-libs / aiokafka

asyncio client for kafka
http://aiokafka.readthedocs.io/
Apache License 2.0
1.17k stars 234 forks source link

Add metrics #38

Open tvoinarovskyi opened 8 years ago

tvoinarovskyi commented 8 years ago
tvoinarovskyi commented 8 years ago

Metrics are still not even documented in kafka-python. I think we should wait until it becomes a stable API there before adding those... For now I'll remove those from 0.2.0 milestone

tvoinarovskyi commented 7 years ago

It's not something too complicated, but requires some time. Basically we need to take the metrics aggregators present in kafka-python and call sensors for respectful events. Like self._sensors.records_fetch_lag.record(highwater - last_offset) after each fetch to record lag samples.

Corfucinas commented 2 years ago

Any progress? Just noticed the consumer does not have the method .metrics()

jigar-bhati commented 1 year ago

Any updates on this? Having producer/consumers metrics for aiokafka seems like a super useful thing to have for debugging client side issues or investigating client vs server problems.

JaredCorduan commented 2 months ago

Exposing metrics would be extremely valuable.

marcosschroh commented 2 months ago

We have the following metrics in our micro framework. The metrics are automatically generated, then you have to expose them in your prefer way. If you are using a web framework it is really easy, for example, otherwise you can use start_wsgi_server from prometheus_client

JaredCorduan commented 2 months ago

Thank you @marcosschroh , I will check this out now!