Function tor_circmgr::mgr::spawn_expiration_task

source ยท
fn spawn_expiration_task<B, R>(
    runtime: &R,
    circmgr: Weak<AbstractCircMgr<B, R>>,
    circ_id: <<B as AbstractCircBuilder>::Circ as AbstractCirc>::Id,
    exp_inst: Instant
)
where R: Runtime, B: 'static + AbstractCircBuilder,
Expand description

Spawn an expiration task that expires a circuit at given instant.

If given instant is earlier than now, expire the circuit immediately. Otherwise, spawn a timer expiration task on given runtime.

When the timeout occurs, if the circuit manager is still present, the task will ask the manager to expire the circuit, if the circuit is ready to expire.