Expand description
Peer Score Tracker for GossipSub mesh management
Tracks composite peer quality scores used by GossipSub mesh management. Combines message delivery rate, topic mesh contribution, and application-level quality signals.
§Examples
use ipfrs_network::peer_score::{PeerScoreTracker, ScoreParameter, BehaviourPenalty};
let mut tracker = PeerScoreTracker::new(ScoreParameter::default());
tracker.get_or_create("peer-1");
let score = tracker.composite_score("peer-1");
println!("Peer score: {score}");Structs§
- Peer
Score - Scoring state for a single peer.
- Peer
Score Tracker - Central tracker that maintains
PeerScoreentries for every known peer and exposes mesh-management queries. - Score
Parameter - Parameters controlling how peer scores are weighted and decayed.
- Topic
Score - Per-peer, per-topic scoring data.
Enums§
- Behaviour
Penalty - Application-level behaviour penalties that can be applied to a peer.