MCPcopy Create free account
hub / github.com/Kilo-Org/cloud / socketWriteServiceUnavailable

Function socketWriteServiceUnavailable

services/kiloclaw/controller/src/proxy.ts:200–203  ·  view source on GitHub ↗
(socket: Duplex)

Source from the content-addressed store, hash-verified

198}
199
200function socketWriteServiceUnavailable(socket: Duplex): void {
201 socket.write('HTTP/1.1 503 Service Unavailable\r\nRetry-After: 5\r\nConnection: close\r\n\r\n');
202 socket.destroy();
203}
204
205function setDuplexTimeout(socket: Duplex, timeoutMs: number, onTimeout: () => void): void {
206 const timeoutCapable = socket as unknown as {

Callers 1

handleWebSocketUpgradeFunction · 0.85

Calls 2

writeMethod · 0.80
destroyMethod · 0.65

Tested by

no test coverage detected