-
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: Add method to inform of deprecated plugin option values #11987
feat: Add method to inform of deprecated plugin option values #11987
Conversation
Hmmm why do we want another function? You could do this using models.PrintOptionDeprecationNotice(telegraf.Warn, "category.pluginname", "optionname", telegraf.DeprecationInfo{
Since: "1.24.3",
RemovalIn: "2.0.0",
Notice: "value 'whatever' deprecated",
}) |
Clearer error message, as your suggestion will say that |
What do you think @srebhan? |
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.
Some minor comments @Hipska...
Co-authored-by: Sven Rebhan <[email protected]>
81dc11d
to
f4ef4b7
Compare
…common value types
!retry-checks |
!retry-failed |
!retry-failed |
Download PR build artifacts for linux_amd64.tar.gz, darwin_amd64.tar.gz, and windows_amd64.zip. 🥳 This pull request decreases the Telegraf binary size by -1.42 % for linux amd64 (new size: 154.9 MB, nightly size 157.1 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.
Added require.Eventually
example.
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.
Beautiful. Thanks for your effort @Hipska!
May I ask you to please convert the existing tests in that file to the same schema in a separate PR to serve as a good example!? :-)
Okay, can you create an Issue for that and assign to me? |
This feature would be used first to deprecate the netsnmp translator. |
Required for all PRs
This will make it possible for plugin authors to deprecate option values they do not support/use anymore.
At the same time, the docs for deprecating options is updated a bit to also include sample for unused options.