Create response channel before sending StartSession (#1208)
This commit is contained in:
@@ -155,6 +155,10 @@ func (r *RedisRouter) StartParticipantSignal(ctx context.Context, roomName livek
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// index by connectionID, since there may be multiple connections for the participant
|
||||||
|
// set up response channel before sending StartSession and be ready to receive responses.
|
||||||
|
resChan := r.getOrCreateMessageChannel(r.responseChannels, string(connectionID))
|
||||||
|
|
||||||
sink := NewRTCNodeSink(r.rc, livekit.NodeID(rtcNode.Id), pKey)
|
sink := NewRTCNodeSink(r.rc, livekit.NodeID(rtcNode.Id), pKey)
|
||||||
|
|
||||||
// serialize claims
|
// serialize claims
|
||||||
@@ -169,8 +173,6 @@ func (r *RedisRouter) StartParticipantSignal(ctx context.Context, roomName livek
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// index by connectionID, since there may be multiple connections for the participant
|
|
||||||
resChan := r.getOrCreateMessageChannel(r.responseChannels, string(connectionID))
|
|
||||||
return connectionID, sink, resChan, nil
|
return connectionID, sink, resChan, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user