Server

Each server definition is a map with two always-required keys:

  • name, which sets the server name

  • type, which selects the concrete server type and therefore the remaining valid keys

The supported server types are documented below.

Servers

Common Keys

This section describes keys shared by multiple server types.

name

required, type: metric node name

Set the server name.

type

required, type: str

Set the server type.

shared_logger

optional, type: ascii

Send this server’s task logs to a logger running on a shared thread.

default: not set

listen_in_worker

optional, type: bool

Set whether each worker runtime should create its own listening socket when worker runtimes are enabled.

When enabled, the number of listening instances matches the worker count.

default: false

ingress_network_filter

optional, type: ingress network acl rule

Set the client-side network ACL.

The address used for matching is always the interpreted client address. For servers that listen directly, this is the socket peer address. For servers behind a PROXY Protocol listener, it is the address carried in the PROXY Protocol message.

default: not set

tcp_sock_speed_limit

optional, type: tcp socket speed limit

Set the speed limit for each TCP socket.

default: no limit

udp_sock_speed_limit

optional, type: udp socket speed limit

Set the speed limit for each UDP socket.

default: no limit

tcp_copy_buffer_size

optional, type: humanize usize

Set the buffer size used for internal TCP copying.

default: 16K, minimal: 4K

tcp_copy_yield_size

optional, type: humanize usize

Set the yield threshold for the internal copy task.

default: 1M, minimal: 256K

tcp_misc_opts

optional, type: tcp misc sock opts

Set additional TCP socket options on accepted sockets.

default: not set, nodelay is default enabled

udp_misc_opts

optional, type: udp misc sock opts

Set additional UDP socket options on created sockets.

default: not set

tls_ticketer

optional, type: tls ticketer

Set a local or remote rolling TLS ticket key provider.

default: not set

Added in version 0.3.6.

task_idle_check_duration

deprecated

Changed in version 0.3.8: change default value from 5min to 60s

Changed in version 0.4.0: deprecated, use task_idle_check_interval instead

task_idle_check_interval

optional, type: humanize duration

Set the idle-check interval for tasks. The effective value is rounded up to a whole number of seconds.

default: 60s, max: 30min, min: 2s

Added in version 0.4.0.

task_idle_max_count

optional, type: usize

Close the task after this many consecutive idle-check results return IDLE.

default: 5

Changed in version 0.3.8: change default value from 1 to 5

flush_task_log_on_created

optional, type: bool

Emit a task log when the task is created.

default: false

Added in version 0.3.8.

flush_task_log_on_connected

optional, type: bool

Emit a task log when the upstream connection is established.

default: false

Added in version 0.3.8.

task_log_flush_interval

optional, type: humanize duration

Enable periodic task logs and set the flush interval.

Note

Periodic task logs are disabled when protocol inspection is enabled, because intercept and inspection logs already provide detailed state updates.

default: not set

Added in version 0.3.8.

extra_metrics_tags

optional, type: static metrics tags

Set additional metrics tags to attach to server statistics.

default: not set