Skip to main content

expire_capacity_rejected

Function expire_capacity_rejected 

Source
pub async fn expire_capacity_rejected(
    bootstrap_state: &Arc<RwLock<BootstrapState>>,
    max_age: Duration,
) -> usize
Expand description

Expire capacity-rejection records whose most recent rejection is older than max_age, returning how many sources were expired.

A source that has not re-delivered within max_age has abandoned its owed re-hints — or departed in a race with its own PeerRemoved cleanup, leaving a record that no admission cycle or removal event can ever clear. Expiry forfeits the keys that source still owed so bootstrap can drain; the post-bootstrap neighbor-sync and audit/repair pipeline recover them (see BootstrapState::capacity_rejected_sources).