1use lazy_static::lazy_static; 2use std::sync::Once; 3 4lazy_static! { 5 static ref INIT: Once = Once::new(); 6} 7 8pub fn start_logger() { 9 INIT.call_once(|| { 10 // install global collector configured based on RUST_LOG env var. 11 tracing_subscriber::fmt::init(); 12 }); 13}