fn json_logs(filter: EnvFilter) {
    use tracing_subscriber::fmt::layer;
    let subscriber = Registry::default().with(filter).with(layer().json());
    tracing::subscriber::set_global_default(subscriber).unwrap();
}
/// Configure global logger to use a json logger.
Configure global logger to use a json logger.
Configure global logger to use a json logger .
fn json_logs(filter: EnvFilter) {
    use tracing_subscriber::fmt::layer;
    let subscriber = Registry::default().with(filter).with(layer().json());
    tracing::subscriber::set_global_default(subscriber).unwrap();
}
fn json_logs ( filter : EnvFilter ) { use tracing_subscriber :: fmt :: layer ; let subscriber = Registry :: default ( ) . with ( filter ) . with ( layer ( ) . json ( ) ) ; tracing :: subscriber :: set_global_default ( subscriber ) . unwrap ( ) ; }
Configure global logger to use a json logger.
Configure global logger to use a json logger .
filter
EnvFilter