mirror of
https://github.com/Moepchi/webspeak3.git
synced 2026-12-01 00:42:49 +08:00
Tell clients when the gateway is full; default limit 60
A browser can't see why a WebSocket upgrade was refused, so a full gateway now accepts, sends a gateway_full error and closes. The client shows a translated hint that includes self-hosting. Default MAX_CONNECTIONS drops from 300 to 60 after measuring ~8-9 % of a core per listening client. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Hu2cuPLqpuKVfd9wWFFakU
This commit is contained in:
1 parent
999262b6df
commit
e02a41d855
8 files changed
+17
-6
No files matched your search
+1
-1
@@ -10256,7 +10256,7 @@ function AppInner() {
|
||||
appendLog({ text: data.message, kind: "error" });
|
||||
} else {
|
||||
setConnecting(false);
|
||||
setConnectError(data.message);
|
||||
setConnectError(data.code === "gateway_full" ? t("connectError.gatewayFull") : data.message);
|
||||
updateTabMeta(sessionId, { connecting: false, connected: false });
|
||||
}
|
||||
break;
|
||||
|
||||
Reference in new issue
Block a user