Skip to content

Commit

Permalink
address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Frando committed May 16, 2024
1 parent 1aceaba commit 240bb21
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions iroh/src/docs_engine/gossip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@ use std::collections::HashSet;

use anyhow::{Context, Result};
use futures_lite::StreamExt;
use futures_util::FutureExt;
use iroh_docs::{actor::SyncHandle, ContentStatus, NamespaceId};
use iroh_gossip::{
net::{Event, Gossip},
proto::TopicId,
};
use iroh_gossip::net::{Event, Gossip};
use iroh_net::key::PublicKey;
use tokio::{
sync::{broadcast, mpsc},
Expand All @@ -16,7 +14,7 @@ use tokio_stream::{
wrappers::{errors::BroadcastStreamRecvError, BroadcastStream},
StreamMap,
};
use tracing::{debug, error, trace};
use tracing::{debug, error, trace, warn};

use super::live::{Op, ToLiveActor};

Expand Down Expand Up @@ -64,7 +62,6 @@ impl GossipActor {
}
}
pub async fn run(&mut self) -> anyhow::Result<()> {
// let mut gossip_events = self.gossip.clone().subscribe_all();
let mut i = 0;
loop {
i += 1;
Expand Down Expand Up @@ -144,7 +141,7 @@ impl GossipActor {
let event = match event {
Ok(event) => event,
Err(BroadcastStreamRecvError::Lagged(n)) => {
error!("GossipActor too slow (lagged by {n}) - dropping gossip event");
warn!("GossipActor too slow (lagged by {n}) - dropping gossip event");
return Ok(());
}
};
Expand Down

0 comments on commit 240bb21

Please sign in to comment.