Files
x/dialer
Andrew Beresford cf70a0cbe1 Add configurable TCP keepalives to TCP listener and dialer
Exposes TCP keepalive configuration via listener and dialer metadata:

  keepalive: true
  keepalive.idle: 30s
  keepalive.interval: 10s
  keepalive.count: 6

When enabled, the OS sends keepalive probes after the idle period and
tears down the socket if the remote does not respond. This causes any
blocked Read() on a dead connection to return promptly, releasing
goroutines and memory — covering both legs of a CONNECT tunnel (the
inbound client connection via the listener, and the outbound upstream
connection via the dialer).

This is the correct alternative to a hard application-level read
deadline (SetReadDeadline) for detecting dead connections, as it
distinguishes truly dead connections from legitimately idle ones.

Relates to: https://github.com/go-gost/x/issues/91
2026-05-08 11:33:54 +01:00
..
2022-11-29 09:45:51 +08:00
2025-08-04 19:29:38 +08:00
2022-04-07 23:03:31 +08:00
2025-08-04 19:29:38 +08:00
2025-08-05 20:24:00 +08:00
2025-06-25 21:06:23 +08:00
2024-10-10 22:49:56 +08:00
2025-08-04 19:29:38 +08:00
2025-08-04 19:29:38 +08:00
2024-10-10 22:49:56 +08:00
2025-06-25 21:06:23 +08:00
2023-10-15 23:55:52 +08:00
2025-08-04 19:29:38 +08:00
2025-08-04 19:29:38 +08:00
2025-08-04 19:29:38 +08:00
2025-11-11 12:37:33 +08:00
2023-09-18 23:14:55 +08:00
2024-07-08 22:38:21 +08:00
2025-08-04 19:29:38 +08:00