web3-proxy/web3_proxy_cli/examples/tracing.rs
2023-08-03 00:16:54 -07:00

17 lines
417 B
Rust

use tracing::info;
fn main() {
// install global collector configured based on RUST_LOG env var.
tracing_subscriber::fmt::init();
let number_of_yaks = 3;
// this creates a new event, outside of any spans.
info!(number_of_yaks, "preparing to shave yaks");
let number_shaved = 3;
info!(
all_yaks_shaved = number_shaved == number_of_yaks,
"yak shaving completed."
);
}