Changed log to tracing
This commit is contained in:
parent
db12bba7a6
commit
48a14823fa
26 changed files with 321 additions and 689 deletions
|
|
@ -8,10 +8,10 @@ use librqbit_core::{
|
|||
peer_id::generate_peer_id,
|
||||
torrent_metainfo::{torrent_from_bytes, TorrentMetaV1Info, TorrentMetaV1Owned},
|
||||
};
|
||||
use log::{debug, info, warn};
|
||||
use parking_lot::RwLock;
|
||||
use reqwest::Url;
|
||||
use tokio_stream::StreamExt;
|
||||
use tracing::{debug, info, span, warn, Level};
|
||||
|
||||
use crate::{
|
||||
dht_utils::{read_metainfo_from_peer_receiver, ReadMetainfoResult},
|
||||
|
|
@ -402,7 +402,7 @@ impl Session {
|
|||
}
|
||||
|
||||
if let Some(mut dht_peer_rx) = dht_peer_rx {
|
||||
spawn("DHT peer adder", {
|
||||
spawn(span!(Level::INFO, "dht_peer_adder"), {
|
||||
let handle = handle.clone();
|
||||
async move {
|
||||
while let Some(peer) = dht_peer_rx.next().await {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue