Skip to main content

decide_delay

Function decide_delay 

Source
pub fn decide_delay(
    buckets: &QuotaBuckets,
    retry_after: Option<RetryAfter>,
    now: WallClockTimestamp,
    previous_now: Option<WallClockTimestamp>,
    policy: QuotaDelayPolicy,
) -> Result<Option<DelayDecision>, DelayDecisionError>
Expand description

Derives a bounded delay without reading a clock or sleeping.