Skip to content
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

chore(inputs.statsd): Refactor internal stats into their own struct #16419

Merged
merged 1 commit into from
Jan 22, 2025

Conversation

Manbeardo
Copy link
Contributor

@Manbeardo Manbeardo commented Jan 21, 2025

Summary:

Later in this stack of diffs, I add a field named MaxConnections to Statsd because it controls the max number of connections for all listener types, not just TCP listeners. That creates a naming collision with the existing field named MaxConnections, which is an internal stat tracker. This diff eliminates that name collision by encapsulating all of Statsd's internal stat trackers in a struct.

Test Plan:

Existing unit tests pass.

Stack created with Sapling. Best reviewed with ReviewStack.

@telegraf-tiger
Copy link
Contributor

Thanks so much for the pull request!
🤝 ✒️ Just a reminder that the CLA has not yet been signed, and we'll need it before merging. Please sign the CLA when you get a chance, then post a comment here saying !signed-cla

…ruct

Summary:

Later in this stack of diffs, I add a field named `MaxConnections` to `Statsd` because it controls the max number of connections for all listener types, not just TCP listeners. That creates a naming collision with the existing field named `MaxConnections`, which is an internal stat tracker. This diff eliminates that name collision by encapsulating all of `Statsd`'s internal stat trackers in a struct.

Test Plan:

Existing unit tests pass.
@Manbeardo Manbeardo changed the title [statsd receiver] encapsulate internal stats in their own struct refactor(statsd receiver): encapsulate internal stats in their own struct Jan 21, 2025
@Manbeardo
Copy link
Contributor Author

!signed-cla

@telegraf-tiger
Copy link
Contributor

Copy link
Member

@DStrand1 DStrand1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Linter failure is unrelated to this PR. Thanks for the work!

@DStrand1 DStrand1 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 Jan 22, 2025
@srebhan srebhan changed the title refactor(statsd receiver): encapsulate internal stats in their own struct chore(inputs.statsd): Refactor internal stats into their own struct Jan 22, 2025
@telegraf-tiger telegraf-tiger bot added area/statsd chore plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins labels Jan 22, 2025
Copy link
Member

@srebhan srebhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @Manbeardo!

@srebhan srebhan merged commit abc3a5e into influxdata:master Jan 22, 2025
32 of 35 checks passed
@github-actions github-actions bot added this to the v1.33.2 milestone Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/statsd chore plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants