We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
tracing::info
1 parent 3da7d91 commit 01f7b40Copy full SHA for 01f7b40
examples/metrics/src/main.rs
@@ -66,6 +66,13 @@ async fn main() -> Result<(), Box<dyn Error>> {
66
67
loop {
68
match swarm.select_next_some().await {
69
+ SwarmEvent::NewListenAddr { address, .. } => {
70
+ tracing::info!(
71
+ "Local node is listening on\n {}/p2p/{}",
72
+ address,
73
+ swarm.local_peer_id()
74
+ );
75
+ }
76
SwarmEvent::Behaviour(BehaviourEvent::Ping(ping_event)) => {
77
tracing::info!(?ping_event);
78
metrics.record(&ping_event);
0 commit comments