Skip to main content

apply_diversity_transition

Function apply_diversity_transition 

Source
fn apply_diversity_transition(
    collapsed_diversity: &Mutex<HashSet<(OffchainPublicKey, OffchainPublicKey, u32)>>,
    src_key: &OffchainPublicKey,
    kind: &str,
    obs: &DiversityObservation,
)
Expand description

Records a diversity transition and logs it once: a WARN when a key first collapses to a single relayer, an INFO when it first recovers. Idempotent across repeated rebuilds of the same state, so the WARN fires on the transition, not on every rebuild.