From 2067820714fea49be1692fa678754488ace8228b Mon Sep 17 00:00:00 2001 From: Leo Kettmeir Date: Thu, 6 Jan 2022 17:41:16 +0100 Subject: feat(ext/websocket): server automatically handle ping/pong for incoming WebSocket (#13172) --- cli/dts/lib.deno.ns.d.ts | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'cli/dts') diff --git a/cli/dts/lib.deno.ns.d.ts b/cli/dts/lib.deno.ns.d.ts index 914c63b24..03ba3d898 100644 --- a/cli/dts/lib.deno.ns.d.ts +++ b/cli/dts/lib.deno.ns.d.ts @@ -2745,6 +2745,14 @@ declare namespace Deno { export interface UpgradeWebSocketOptions { protocol?: string; + /** + * If the client does not respond to this frame with a + * `pong` within the timeout specified, the connection is deemed + * unhealthy and is closed. The `close` and `error` event will be emitted. + * + * The default is 120 seconds. Set to 0 to disable timeouts. + */ + idleTimeout?: number; } /** -- cgit v1.2.3