From a412ea4984a46d50de8873904b7067897b0f29f9 Mon Sep 17 00:00:00 2001 From: Jonas Gloning <34194370+jonasgloning@users.noreply.github.com> Date: Wed, 27 Apr 2022 02:21:44 +0200 Subject: [PATCH] perf(turn): lower TURN-latency due to more local servers --- lib/util.ts | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/lib/util.ts b/lib/util.ts index de7b77ee8..1079134a0 100644 --- a/lib/util.ts +++ b/lib/util.ts @@ -14,7 +14,18 @@ const DEFAULT_CONFIG = { iceServers: [ { urls: "stun:stun.l.google.com:19302" }, { - urls: "turn:0.peerjs.com:3478", + urls: [ + "turn:eu-0.turn.peerjs.com:3478", + "turn:eu-1.turn.peerjs.com:3478", + ], + username: "peerjs", + credential: "peerjsp", + }, + { + urls: [ + "turn:us-0.turn.peerjs.com:3478", + "turn:us-1.turn.peerjs.com:3478", + ], username: "peerjs", credential: "peerjsp", },