Skip to main content

Module budget

Module budget 

Source
Expand description

One total budget per attempt (spec 009, 3.4.1 and I-5): the remaining time at dispatch. Every transport phase draws from it; no phase limit can outlive it; the remote side is told the budget minus a declared transit margin.

Structs§

Budget
The deadline of one attempt (or one exchange), by Tokio’s monotonic clock, fixed at dispatch.
Expired
The budget ran out before the phase finished.
TimeoutBeyondBudget
A configured transport timeout that could outlive the budget it serves (spec 009, section 6: refused at construction).

Functions§

check_transport_timeout
Refuse a transport timeout longer than the budget available where the adapter is constructed. Adapters call this before any network use.