Skip to content

feat(outputs.influxdb_v2): report selfstats on errors and bytes #17277

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

LarsStegman
Copy link
Contributor

@LarsStegman LarsStegman commented Jul 2, 2025

Summary

We want to keep track of how many bytes we are sending over a satellite connection, since we sometimes accidentally push away other traffic. I am not sure how (and if) to test these new metrics.

Checklist

  • No AI generated code was used in this PR

Related issues

resolves #17275

@telegraf-tiger telegraf-tiger bot added area/influxdb feat Improvement on an existing feature such as adding a new setting/mode to an existing plugin plugin/output 1. Request for new output plugins 2. Issues/PRs that are related to out plugins labels Jul 2, 2025
@mstrandboge mstrandboge self-assigned this Jul 2, 2025
@telegraf-tiger
Copy link
Contributor

telegraf-tiger bot commented Jul 3, 2025

Download PR build artifacts for linux_amd64.tar.gz, darwin_arm64.tar.gz, and windows_amd64.zip.
Downloads for additional architectures and packages are available below.

☺️ This pull request doesn't significantly change the Telegraf binary size (less than 1%)

📦 Click here to get additional PR build artifacts

Artifact URLs

. DEB . RPM . TAR . GZ . ZIP
[[amd64.deb aarch64.rpm darwin_amd64.tar.gz windows_amd64.zip] [arm64.deb armel.rpm darwin_arm64.tar.gz windows_arm64.zip] [armel.deb armv6hl.rpm freebsd_amd64.tar.gz windows_i386.zip] [armhf.deb i386.rpm freebsd_armv7.tar.gz ] [i386.deb ppc64le.rpm freebsd_i386.tar.gz ] [mips.deb riscv64.rpm linux_amd64.tar.gz ] [mipsel.deb s390x.rpm linux_arm64.tar.gz ] [ppc64el.deb x86_64.rpm linux_armel.tar.gz ] [riscv64.deb linux_armhf.tar.gz ] [s390x.deb linux_i386.tar.gz ] [ linux_mips.tar.gz ] [ linux_mipsel.tar.gz ] [ linux_ppc64le.tar.gz ] [ linux_riscv64.tar.gz ] [ linux_s390x.tar.gz ]]

@LarsStegman
Copy link
Contributor Author

Done, the failing integration test is not related to my changes

@mstrandboge mstrandboge assigned skartikey and srebhan and unassigned mstrandboge Jul 15, 2025
@mstrandboge mstrandboge added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Jul 15, 2025
@srebhan srebhan removed the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Jul 16, 2025
@srebhan
Copy link
Member

srebhan commented Jul 16, 2025

@LarsStegman your approach unfortunately has some issues...If people define some tags or an alias your metric it will not be possible to associate your metric to the one of the plugin. However, this is not solvable from within the plugin as it will not have access to this information.

I'm working on a PR for allowing plugins to export statistics with those information added. Hope to put up a spec today and I do have a PoC I can share so you can base your PR on. Will share both PRs here later today...

Sorry for not solving this issue earlier...

@LarsStegman
Copy link
Contributor Author

Hey Sven, no problem. I already suspected I was missing something, because this way of creating stats is not used anywhere else as far as I can see.

@srebhan
Copy link
Member

srebhan commented Jul 16, 2025

@LarsStegman please let check the spec in PR #17344 and a draft PR for adding the framework in PR #17345.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/influxdb feat Improvement on an existing feature such as adding a new setting/mode to an existing plugin plugin/output 1. Request for new output plugins 2. Issues/PRs that are related to out plugins
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat(outputs.influxdb_v2): report total amount of bytes sent, number of retries, number of failures
4 participants