Unlink peer spans from their creation details.
@@ -76,7 +76,10 @@ where
let (tcp_stream, addr) = req;
let connector_span = span!(Level::INFO, "connector", addr = ?addr);
- let connection_span = span!(Level::INFO, "peer", addr = ?addr);
+ // set parent: None for the peer connection span, as it should exist
+ // independently of its creation source (inbound connection, crawler,
+ // initial peer, ...)
+ let connection_span = span!(parent: None, Level::INFO, "peer", addr = ?addr);
// Clone these upfront, so they can be moved into the future.
let nonces = self.nonces.clone();
