-
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
fix(inputs.bind): Convert counters to uint64 #16015
Conversation
1c7a50b
to
5c11819
Compare
not able to download package. is it included on v1.32.1 [2024-10-07] ? |
@rumanmaharjan I retriggered building of the packages. Please note, those packages will be deleted after 3 days IIRC so it would be good if you could at least download the package before it is removed again... |
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.
@srebhan Could you also rebase this PR to fix the changelog merge conflict? Thanks!
Co-authored-by: Dane Strandboge <[email protected]>
9ec4b85
to
64d4f16
Compare
Download PR build artifacts for linux_amd64.tar.gz, darwin_arm64.tar.gz, and windows_amd64.zip. 👍 This pull request doesn't change the Telegraf binary size 📦 Click here to get additional PR build artifactsArtifact URLs |
(cherry picked from commit 9c8196f)
Summary
The bind implementation of the XML v3 endpoint reports counters as unsigned integers through XML. However, the current implementation of the plugin tries to convert those numbers to signed integers which fails for large values of counters leading to a parsing error as shown in the related issue.
This PR changes the internal representation of the counters to unsigned integers for the XML v3 implementation. The PR also adds a
report_counters_as_int
to keep the current, backward-compatible behavior of reporting those counters as signed integer fields. To avoid type conflicts and keep backward-compatibility the default behavior is to continue reporting those counters as integers.However, users should change the setting to
false
as soon as possible to avoid parsing errors!Checklist
Related issues
resolves #15866