hopr_transport_network/
lib.rs

1//! Network and physical transport related utilities
2//!
3//! This package contains objects and utilities that allow storing and
4//! querying the current state of the observable `Network`.
5//!
6//! Background processes and event updates ensure that the Network data is
7//! regularly updated to offer the complete information about each observed
8//! peer:
9//! 1. the timestamps of last observations
10//! 2. quality measurements based on the heartbeat and ping reporting mechanism,
11//! 3. individual metrics counting windowed quality characteristics
12//! 4. on and off-chain observed peer related data (multiaddresses...)
13//!
14//! NOTE: This object has not been significantly altered from the previous versions
15//! and will be improved in the upcoming releases together with physical transport
16//! upgrades that will make it possible to record more data faster. As such, this
17//! object should slowly transform into a pollable physical network graph processing
18//! live telemetry from the packet transport process.
19
20/// Configuration of the network module.
21pub mod config;
22
23/// Global constants published from this crate.
24pub mod constants;
25/// Errors that can be generated by the crate.
26pub mod errors;
27/// Implementation of the main loop for the heartbeat mechanism.
28pub mod heartbeat;
29/// Low-level transport protocol messaging definitions for [ping].
30pub mod messaging;
31/// Implementation of the peer network logic
32pub mod network;
33/// Implementation of the pinging mechanism used by the [heartbeat] and manual pings.
34pub mod ping;
35
36pub use hopr_db_api::peers::HoprDbPeersOperations;
37pub use libp2p_identity::PeerId;