-
Notifications
You must be signed in to change notification settings - Fork 795
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
Place the node role as a label value #207
Comments
Hi @jorgelbg, we deliberately decided to encode the role info as bool-style key/value pairs. Your proposed node role label can have multiple roles and a role label value could be for example What do you think, @marthjod , @metalmatze ? |
@zwopir Thanks for the reply and for opening a discussion about this. Regarding the multiple roles I've run into this scenario as well. I have some nodes with mixed roles in my clusters as well. Indeed, I was thinking about a similar approach to the one discussed here https://www.robustperception.io/how-to-have-labels-for-machine-roles. But perhaps this approach could cause some other issues 🤔. |
that's actually a very nice solution to our problem. I wasn't of it. Thanks for bringing it up! Later in the life-cycle if the exporter we may even think of deprecating the |
see #228 |
Hi @zwopir, so sorry that I forgot to submit the PR for this issue 😓. I will test the changes in #228 and report here. As a side note, if you run the prometheus node exporter (for the machine metrics) along the elasticsearch exporter, there is the
|
thanks for sharing the query. Most of the service discoveries in prometheus offer the possibility to export machine/node meta data as a label (with some relabeling config needed), but in case you're not using a SD, your trick can be handy. |
implemented the feature in #228 |
At the moment the role of each server in the cluster is stored in a label with a
true/false
value:This provides the ability to filter by a given role in the cluster, but it's not very friendly to dashboard solutions.
Having the role as the value of a label (
...,role="client",...
) could be easier to integrate into some dashboarding solutions. For instance, on Grafana, this value could be fetched from the metric with thelabel_values(metric, label)
function. This would allow using the "values group" feature.So far the alternative that I've found for this is to accomplish this using relabeling. If the feature is welcomed I can submit a PR.
The text was updated successfully, but these errors were encountered: