Set participant active when peerconnection connected (#3790)
Don't wait datachannel ready (sctp handshake)
This commit is contained in:
@@ -1947,10 +1947,6 @@ func (p *ParticipantImpl) updateState(state livekit.ParticipantInfo_State) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if state == livekit.ParticipantInfo_ACTIVE {
|
|
||||||
p.replayJoiningReliableMessages()
|
|
||||||
}
|
|
||||||
|
|
||||||
p.params.Logger.Debugw("updating participant state", "state", state.String())
|
p.params.Logger.Debugw("updating participant state", "state", state.String())
|
||||||
p.dirty.Store(true)
|
p.dirty.Store(true)
|
||||||
|
|
||||||
@@ -2351,15 +2347,17 @@ func (p *ParticipantImpl) onPrimaryTransportInitialConnected() {
|
|||||||
// else, wait for all tracks to be published and publisher peer connection established
|
// else, wait for all tracks to be published and publisher peer connection established
|
||||||
p.SetMigrateState(types.MigrateStateComplete)
|
p.SetMigrateState(types.MigrateStateComplete)
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
func (p *ParticipantImpl) onPrimaryTransportFullyEstablished() {
|
|
||||||
if !p.sessionStartRecorded.Swap(true) {
|
if !p.sessionStartRecorded.Swap(true) {
|
||||||
prometheus.RecordSessionStartTime(int(p.ProtocolVersion()), time.Since(p.params.SessionStartTime))
|
prometheus.RecordSessionStartTime(int(p.ProtocolVersion()), time.Since(p.params.SessionStartTime))
|
||||||
}
|
}
|
||||||
p.updateState(livekit.ParticipantInfo_ACTIVE)
|
p.updateState(livekit.ParticipantInfo_ACTIVE)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (p *ParticipantImpl) onPrimaryTransportFullyEstablished() {
|
||||||
|
p.replayJoiningReliableMessages()
|
||||||
|
}
|
||||||
|
|
||||||
func (p *ParticipantImpl) clearDisconnectTimer() {
|
func (p *ParticipantImpl) clearDisconnectTimer() {
|
||||||
p.lock.Lock()
|
p.lock.Lock()
|
||||||
if p.disconnectTimer != nil {
|
if p.disconnectTimer != nil {
|
||||||
|
|||||||
Reference in New Issue
Block a user