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

Close socket during initialization #808

Merged
merged 2 commits into from
Jan 10, 2024
Merged

Close socket during initialization #808

merged 2 commits into from
Jan 10, 2024

Conversation

vickenty
Copy link
Contributor

@vickenty vickenty commented Dec 21, 2023

What does this PR do?

Make sure statsd uses socket settings configured in initialize.

Description of the Change

If the global statsd instance is used before initialize() is called (for example, statsd used to send metrics from a top-level of a loaded module), statsd instance will already have a socket open when we set connection parameters. To make sure they take effect, call close_socket().

Alternate Designs

Possible Drawbacks

Verification Process

Additional Notes

Release Notes

Review checklist (to be filled by reviewers)

  • Feature or bug fix MUST have appropriate tests (unit, integration, etc...)
  • PR title must be written as a CHANGELOG entry (see why)
  • Files changes must correspond to the primary purpose of the PR as described in the title (small unrelated changes should have their own PR)
  • PR must have one changelog/ label attached. If applicable it should have the backward-incompatible label attached.
  • PR should not have do-not-merge/ label attached.
  • If Applicable, issue must have kind/ and severity/ labels attached at least.

If the global statsd instance is used before initialize() is
called (for example, statsd used to send metrics from a top-level of a
loaded module), statsd instance will already have a socket open when
we set connection parameters. To make sure they take effect, call
close_socket().
@vickenty vickenty marked this pull request as ready for review January 3, 2024 15:53
@vickenty vickenty requested review from a team as code owners January 3, 2024 15:54
@vickenty vickenty added the changelog/Fixed Fixed features results into a bug fix version bump label Jan 4, 2024
@vickenty vickenty merged commit c80f986 into master Jan 10, 2024
11 checks passed
@vickenty vickenty deleted the vickenty/close-init branch January 10, 2024 16:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog/Fixed Fixed features results into a bug fix version bump
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants