Expand description
Shared buffered trace log writer with flush-on-exit support.
Provides a BufWriter-backed file writer wrapped in Arc<Mutex<..>> so the
tracing fmt::layer can write efficiently (batched syscalls) while still
allowing an explicit flush_trace_log() call on process exit or signal.
Structs§
- Flushable
Writer - A clonable, thread-safe buffered writer that implements
std::io::Writeso it can be passed directly totracing_subscriber::fmt::layer().with_writer(..).
Functions§
- flush_
trace_ log - Flush the global trace log writer to disk.