Fix ICE connection fallback (#2144)
* Fix ICE connection fallback Short connection detection relied on iceFailedTimeout, which previously had been misinterpreted. Since we've reduced iceFailedTimeout, it is creating false negatives. We'll instead use PingTimeout since clients are expected to keep the signal connection active. * reduce ping interval to align with total ice failure timeout
This commit is contained in:
@@ -59,9 +59,10 @@ const (
|
||||
negotiationFailedTimeout = 15 * time.Second
|
||||
dtlsRetransmissionInterval = 100 * time.Millisecond
|
||||
|
||||
iceDisconnectedTimeout = 10 * time.Second // compatible for ice-lite with firefox client
|
||||
iceFailedTimeout = 5 * time.Second // time between disconnected and failed
|
||||
iceKeepaliveInterval = 2 * time.Second // pion's default
|
||||
iceDisconnectedTimeout = 10 * time.Second // compatible for ice-lite with firefox client
|
||||
iceFailedTimeout = 5 * time.Second // time between disconnected and failed
|
||||
iceFailedTimeoutTotal = iceFailedTimeout + iceDisconnectedTimeout // total time between connecting and failure
|
||||
iceKeepaliveInterval = 2 * time.Second // pion's default
|
||||
|
||||
minTcpICEConnectTimeout = 5 * time.Second
|
||||
maxTcpICEConnectTimeout = 12 * time.Second // js-sdk has a default 15s timeout for first connection, let server detect failure earlier before that
|
||||
|
||||
Reference in New Issue
Block a user