handle client reconnect with ICE restarts

This commit is contained in:
David Zhao
2021-04-19 16:51:20 -07:00
parent b8c9d05d3e
commit 3b236f0d72
5 changed files with 92 additions and 8 deletions
+6
View File
@@ -196,6 +196,12 @@ func (r *RoomManager) StartSession(roomName string, pi routing.ParticipantInit,
prevSink.Close()
}
participant.SetResponseSink(responseSink)
if err := participant.ICERestart(); err != nil {
logger.Warnw("could not restart ICE",
"participant", pi.Identity,
"error", err,
)
}
return
} else {
// we need to clean up the existing participant, so a new one can join