Иной подход к звонкам

This commit is contained in:
Халимов Рустам
2026-03-11 15:18:35 +03:00
parent 9d2d7efbf1
commit 18f39ecea8
4 changed files with 5 additions and 51 deletions

View File

@@ -21,18 +21,16 @@ interface CallModalProps {
} | null;
}
// ICE servers cache (fetched from server, includes TURN credentials when configured)
// ICE servers cache (fetched from server)
let cachedIceConfig: RTCConfiguration | null = null;
let iceCacheFetchedAt = 0;
const ICE_CACHE_TTL = 3600_000; // 1 hour
const FALLBACK_ICE: RTCConfiguration = {
iceServers: [
{ urls: 'stun:stun.yandex.ru:3478' },
{ urls: 'stun:stun.sipnet.net:3478' },
{ urls: 'stun:stun.l.google.com:19302' },
{ urls: 'stun:stun1.l.google.com:19302' },
{ urls: 'stun:stun2.l.google.com:19302' },
{ urls: 'stun:stun3.l.google.com:19302' },
{ urls: 'stun:stun4.l.google.com:19302' },
],
};