Pass back serverRegion in when participant's joining (#479)

* Pass back serverRegion in when participant's joining

* fix tests

* protocol update
This commit is contained in:
David Zhao
2022-03-02 13:36:19 -08:00
committed by GitHub
parent c743d2ab3a
commit 7a5b5dbc69
8 changed files with 29 additions and 24 deletions
+2
View File
@@ -599,6 +599,7 @@ func (p *ParticipantImpl) SendJoinResponse(
roomInfo *livekit.Room,
otherParticipants []*livekit.ParticipantInfo,
iceServers []*livekit.ICEServer,
region string,
) error {
// send Join response
return p.writeMessage(&livekit.SignalResponse{
@@ -608,6 +609,7 @@ func (p *ParticipantImpl) SendJoinResponse(
Participant: p.ToProto(),
OtherParticipants: otherParticipants,
ServerVersion: version.Version,
ServerRegion: region,
IceServers: iceServers,
// indicates both server and client support subscriber as primary
SubscriberPrimary: p.SubscriberAsPrimary(),