Improvements to system_networkState (#2088)

This commit is contained in:
Pierre Krieger authored and Gav Wood committed 2019-03-26 14:45:11 +01:00
1 parent da124d74d1
commit a9420424b2
7 files changed
+49 -23

No files matched your search

+7
View File
@@ -23,6 +23,8 @@ use libp2p::PeerId;
use parking_lot::Mutex;
use std::sync::Arc;
pub use serde_json::Value;
/// Shared part of the peer set manager (PSM). Distributed around the code.
pub struct Peerset {
tx: mpsc::UnboundedSender<Message>,
@@ -297,6 +299,11 @@ impl PeersetMut {
}
alloc_slots(&mut inner, &self.parent.tx);
}
/// Produces a JSON object containing the state of the peerset manager, for debugging purposes.
pub fn debug_info(&self) -> serde_json::Value {
serde_json::Value::Null
}
}
impl Stream for PeersetMut {