Skip to main content

DEFAULT_LOG_CHAN_SIZE

Constant DEFAULT_LOG_CHAN_SIZE 

Source
pub const DEFAULT_LOG_CHAN_SIZE: usize = 20_000;
Expand description

Default number of records slog-async buffers before it begins dropping them.

slog-async’s own default of 128 is trivially overrun: the consumer only needs to stall briefly (scheduling, a slow write) for the buffer to fill, and each dropped record then produces an ERROR level “channel overflow” report of its own, converting filtered-out records into unfilterable noise. Sized instead for seconds of headroom at a high logging rate; ~110 bytes per slot is allocated up front, so this costs roughly 2MB resident.