-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add mqtt2prometheus push gateway to third party tools #1649
Conversation
Signed-off-by: Christoph Petrausch <chrobbert@gmail.com>
01276f5
to
c276237
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like a reasonable idea. But it would be nice if the MQTT messages were more "Prometheus Native", as in they included the counter/gauge information so the exporter could Set()
or Inc()
appropriately without having to configure it.
Is this working off an existing standard way that someone would already would have things setup, or would they have to set all of the pushing to MQTT with such and such a topic name with specifically formatted data just to use this? What happens when a sensor stops publishing or no longer exists? I'm concerned that this might be inventing a new way of doing things rather than building on what a user is likely to already have, in which case as per above using the Prometheus format would be better. |
Also how does it compare to alternatives? I know there are multiple of the. |
Hello, |
At the moment the exporter caches the ingested metrics for a configurable time. If there is no update during the cache time, the exporter discard the value and do not present it anymore. I work on a solution using timestamps. |
Thanks for the explanation, this sounds like this is trying to work with what exists rather than inventing a whole new thing. The inuits one seems to require devices to be coded for it. The tg44 is more generic, however also appears to include an entire bespoke client library which is a bit odd, and has a smaller community. Accordingly I'd be tending towards this one. The readme indicates that this is an analog of the pushgateway. This is in fact explicitly not the sort of use case that pushgateway is for. Can you correct this please? The text in this PR should also only be the exporter name. This should probably go up in messaging systems. In terms of general comments to help you improve your exporter it'd be good if your temperature examples included _celsius as a suffix on the metric name. Your default port number is outside of https://github.com/prometheus/prometheus/wiki/Default-port-allocations, so presuming there's not some technical consideration I'm missing I'd suggest changing it. As an aside, if that ends up not being sophisticated enough you should take a look at how the JMX and SNMP exporters approach this. Given it's JSON hopefully you can avoid that level of complexity though. |
Updated documentation
Updated documentation
ae56a11
to
f379b1f
Compare
Signed-off-by: Christoph Petrausch <chrobbert@gmail.com>
f379b1f
to
f2ccc06
Compare
Signed-off-by: Christoph Petrausch <chrobbert@gmail.com>
Thanks! |
No description provided.