Skip to main content

DEFAULT_SOCKET_SEND_BUFFER

Constant DEFAULT_SOCKET_SEND_BUFFER 

Source
pub const DEFAULT_SOCKET_SEND_BUFFER: usize = _; // 2_097_152usize
Expand description

Default UDP socket send buffer to request, in bytes.

The mirror of DEFAULT_SOCKET_RECV_BUFFER on the way out: capped by net.core.wmem_max rather than rmem_max, and drained by the network interface rather than by this process. It binds on the same bursts, with a milder ending: when the endpoint hands the kernel more at once than the buffer holds, the send returns EAGAIN and quinn holds the packet until the socket drains — a stall rather than a drop, though the kernel still counts each one as a send buffer error in netstat -su.

Requested when the socket is created, so this is a startup-only setting. Zero leaves the operating system’s own value alone.