fn logfile_layer<S>( config: &LogfileConfig, granularity: Duration, mistrust: &Mistrust ) -> Result<(impl Layer<S> + Send + Sync + Sized, WorkerGuard)>
Try to construct a non-blocking tracing [
Layer] for writing data to an
optionally rotating logfile.
On success, return that layer, along with a WorkerGuard that needs to be dropped when the program exits, to flush buffered messages.