Skip to main content

PeerRegistry

Trait PeerRegistry 

Source
pub trait PeerRegistry: Send + Sync {
    // Required methods
    fn peers(&self) -> Vec<String>;
    fn source_for(&self, peer: &str) -> Option<Arc<dyn SubscriptionSource>>;
}
Expand description

Known remote peers in the yubaba mesh.

Injected into the supervisor at boot. On a local-only camp use NoPeers. Federated subscriptions are opened ONCE per peer per rule — not once per event — per the arch doc §Subscriptions efficiency story.

Required Methods§

Source

fn peers(&self) -> Vec<String>

Source

fn source_for(&self, peer: &str) -> Option<Arc<dyn SubscriptionSource>>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§