-
-
Notifications
You must be signed in to change notification settings - Fork 376
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
[TURN] Fix server relay UDP port not release problem. #330
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this seems reasonable to me
Codecov ReportBase: 59.53% // Head: 59.52% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #330 +/- ##
==========================================
- Coverage 59.53% 59.52% -0.01%
==========================================
Files 503 503
Lines 47646 47646
Branches 12583 12583
==========================================
- Hits 28364 28361 -3
- Misses 9898 9902 +4
+ Partials 9384 9383 -1
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your work @clia 👍 One comment I have is about DropNotifier
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
@clia could you please add a changelog entry (CHANGELOG.md)? |
Changelog entry added. |
We can merge this I think, I do think using the Tokio's |
I just don't want to introduce another dependency library. |
Hmm, good point. I thought it would already be somewhere in the dependency graph, but I guess it isn't |
On our servers, we found that after the TURN service runs for a long time, there will be a large number of UDP ports that are not released.
We found that the reason is that after the
packet_handler
task is started, if the client no longer uses the UDP connection,relay_socket.recv_from
will never return. So we add a 10-second timeout here to check whether the allocation has been dropped every 10 seconds.Fixes #232
Refs webrtc-rs/turn#13