Avoid reconnect loop for unsupported downtrack (#1754)

* Avoid reconnect loop for unsupported downtrack

If the client subscribes to a track which codec is unsupported by the
client, sfu will trigger negotiation failed and issue a full reconnect
after received client answer. If the client try to subscribe that track
then it will got full reconnect again. That will cause a infinite
reconnect loop until the client don't subscribe that track. This PR
will unsubscribe the error track for the client and send a
SubscriptionResponse that contain the reason to indicates the track's
codec is not supported to avoid the reconnect loop.
This commit is contained in:
cnderrauber
2023-05-31 11:41:22 +08:00
committed by GitHub
parent 13d599d2d9
commit c1842cb54f
14 changed files with 226 additions and 47 deletions
+2 -2
View File
@@ -18,8 +18,8 @@ require (
github.com/jxskiss/base62 v1.1.0
github.com/livekit/mageutil v0.0.0-20230125210925-54e8a70427c1
github.com/livekit/mediatransportutil v0.0.0-20230523035537-27577c4e1646
github.com/livekit/protocol v1.5.8-0.20230525225706-52cca4239cf2
github.com/livekit/psrpc v0.3.1-0.20230518234341-6f6847e10b09
github.com/livekit/protocol v1.5.8-0.20230531030840-2a4d1a607ba3
github.com/livekit/psrpc v0.3.1-0.20230528083849-53d664c6d912
github.com/mackerelio/go-osstat v0.2.4
github.com/magefile/mage v1.15.0
github.com/maxbrunsfeld/counterfeiter/v6 v6.6.1