ice icon indicating copy to clipboard operation
ice copied to clipboard

Avoid unnecessary turn address resolution in the turn client

Open amanakin opened this issue 10 months ago • 2 comments

Description

The turn.NewClient function in the library currently requires TURN server addresses passed to it to be resolvable. This causes an error when using a proxy, as the TURN address might only be resolvable by the proxy server itself, not by the client application initiating the connection.

To avoid this error in proxy scenarios, this PR modifies the initialization to omit the TURN address when creating the turn.Client.

Blocker: This change depends on functionality introduced in pion/turn Pull Request #450.

amanakin avatar Apr 16 '25 09:04 amanakin

Codecov Report

:x: Patch coverage is 83.33333% with 3 lines in your changes missing coverage. Please review. :white_check_mark: Project coverage is 78.83%. Comparing base (dd072ed) to head (56d07e3). :warning: Report is 11 commits behind head on master.

Files with missing lines Patch % Lines
gather.go 83.33% 2 Missing and 1 partial :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #773      +/-   ##
==========================================
- Coverage   78.84%   78.83%   -0.02%     
==========================================
  Files          41       41              
  Lines        5441     5452      +11     
==========================================
+ Hits         4290     4298       +8     
- Misses        921      923       +2     
- Partials      230      231       +1     
Flag Coverage Δ
go 78.83% <83.33%> (-0.02%) :arrow_down:
wasm 27.03% <0.00%> (-0.06%) :arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

codecov[bot] avatar Apr 17 '25 01:04 codecov[bot]

@amanakin I released a new version of pion/turn if you want to update the go.mod!

Sean-Der avatar Apr 17 '25 15:04 Sean-Der