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

Properly close UDPSocket before creating a new one (with tests) #143

Merged
merged 2 commits into from
Apr 9, 2020

Conversation

kbogtob
Copy link
Contributor

@kbogtob kbogtob commented Apr 9, 2020

Thanks to @zachmccormick for fixing a bug in #142, I'm just adding tests to fix the branch.

zachmccormick and others added 2 commits April 5, 2020 18:08
Unless you properly call `close()` on the UDPSocket object, unclosed
sockets will very quickly accumulate. If you are sending stats to
StatsD quickly, then you may actually run out of free ports. This
changes the retry behavior to close the port before trying to open a new
one.
@kbogtob kbogtob requested a review from remeh April 9, 2020 08:29
@kbogtob kbogtob self-assigned this Apr 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants