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

Fix "conn" leaking #351

Merged
merged 1 commit into from
Jan 2, 2020
Merged

Fix "conn" leaking #351

merged 1 commit into from
Jan 2, 2020

Conversation

martelli
Copy link
Contributor

@martelli martelli commented Jan 2, 2020

On machines with many NICs, it can cause the golang runtime to run out of threads.

pmazzini
pmazzini previously approved these changes Jan 2, 2020
Copy link
Collaborator

@pmazzini pmazzini left a comment

Choose a reason for hiding this comment

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

lgtm. Thanks for fixing it.

@pmazzini pmazzini closed this Jan 2, 2020
@pmazzini pmazzini reopened this Jan 2, 2020
@codecov
Copy link

codecov bot commented Jan 2, 2020

Codecov Report

Merging #351 into master will decrease coverage by 0.16%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #351      +/-   ##
==========================================
- Coverage   72.13%   71.96%   -0.17%     
==========================================
  Files          79       79              
  Lines        3994     3970      -24     
==========================================
- Hits         2881     2857      -24     
  Misses        954      954              
  Partials      159      159
Impacted Files Coverage Δ
netboot/rtnetlink_linux.go 55.55% <100%> (+5.55%) ⬆️
dhcpv6/option_iaprefix.go 88.57% <0%> (-1.43%) ⬇️
dhcpv6/option_prefixdelegation.go 100% <0%> (ø) ⬆️
dhcpv6/option_nontemporaryaddress.go 100% <0%> (ø) ⬆️
dhcpv6/option_iaaddress.go 100% <0%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9a95b10...146564d. Read the comment docs.

@pmazzini
Copy link
Collaborator

pmazzini commented Jan 2, 2020

Go tip linter check is failing but it is unrelated to this PR

https://travis-ci.org/insomniacslk/dhcp/builds/631842573

@pmazzini pmazzini closed this Jan 2, 2020
@pmazzini pmazzini reopened this Jan 2, 2020
@pmazzini
Copy link
Collaborator

pmazzini commented Jan 2, 2020

The error looks to be a golangci-lint issue: golangci/golangci-lint#896

I would go ahead and merge this PR but I can only do so if travis run was successful.

cc @insomniacslk

@insomniacslk
Copy link
Owner

@pmazzini i can force the merge. However I'd like a check of the return value of Close() before, and logging a warning if it fails, cc @martelli

…chines with many NICs

Signed-off-by: Leandro Martelli <[email protected]>
@martelli
Copy link
Contributor Author

martelli commented Jan 2, 2020

I've refactored it to log any error messages.

Copy link
Collaborator

@pmazzini pmazzini left a comment

Choose a reason for hiding this comment

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

lgtm

@insomniacslk insomniacslk merged commit 492d592 into insomniacslk:master Jan 2, 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