-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
feat(outputs.nebius_cloud_monitoring): Add 'service' configuration setting #14658
Conversation
@abrekhov can you explain how this parameter can be used?!? It says "normally is should not be changed", so I wonder when to change it and where to find the value to change it to... |
But few weeks ago DevTeam of Nebius Cloud came to me and said that they want to use telegraf in service monitoring (from the side of the cloud). And they use this service parameter to identify to which service this metrics belongs (e.g. managed postgres cluster, or data-proc service, etc.). So this comment about "normally is should not be changed" is for end customers who want to gather custom metrics from VMs. Could you please also point me where did I fail with the semantic of PR? |
If your PR only contains a single commit, the semantic checker uses that to check for a semantic message. In your case:
When you have more than one commit, then the checker will look at the PR title. |
@abrekhov - what is the consequence of changing that value? As in, if I am a user and change it to "backend" thinking I am monitoring my own backend, will metrics get rejected? Or show up differently? |
As I understand this metrics will be rejected. But if devteam starts to monitor VMs from managed service side and set it to managed-postgres, then it will be processed and user will see such metrics from managed service : |
@srebhan and I are both concerned that this will cause confusion and mistakes by users. However, we would love to enable the backend team to utilize telegraf. Could we instead of a config option have the backend team set an environment variable which changes this setting? That way the option stays out of the config a user would see and it would prevent possibly setting this incorrectly. Thanks! |
Great idea! Could you provide some example in other plugin where it is implemented? |
Essentially you will want to override the value if an environment variable like So you can update your logic to something like: if a.service == "" {
a.service = "custom"
}
if service := os.Getenv("NEBIUS_SERVICE"); service != "" {
a.service = service
} Does that help? |
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.
Thanks!
Could you please explain why lint-linux job is failing over and over again? |
Ah I had missed that:
You made two changes:
To be honest, the yandex change doesn't really belong as a part of this PR and I hesitated when I saw that, but if you make the corresponding update to the sample.conf we can include it. |
I've executed |
Download PR build artifacts for linux_amd64.tar.gz, darwin_arm64.tar.gz, and windows_amd64.zip. 🥳 This pull request decreases the Telegraf binary size by -3.20 % for linux amd64 (new size: 221.5 MB, nightly size 228.8 MB) 📦 Click here to get additional PR build artifactsArtifact URLs |
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.
Awesome! Thanks @abrekhov!
Summary
Internal dev team of Nebius Managed Services came to me and asked to make this parameter configurable.
Checklist
Related issues
resolves #14657