pub struct RateLeaseSnapshot {
pub kind: String,
pub tokens: f64,
pub last_refill_ms: i64,
pub window_start_ms: i64,
pub consumed: i64,
}Expand description
§Fase 72.e — a RateLease’s persistable state (epoch-millis wire form). The
enterprise supervisor stores one per quota subject key so budgets are
cumulative across a daemon’s ticks. kind discriminates which fields are
live (rate ⇒ tokens/last_refill_ms; max ⇒ window_start_ms/consumed).
Fields§
§kind: String§tokens: f64§last_refill_ms: i64§window_start_ms: i64§consumed: i64Trait Implementations§
Source§impl Clone for RateLeaseSnapshot
impl Clone for RateLeaseSnapshot
Source§fn clone(&self) -> RateLeaseSnapshot
fn clone(&self) -> RateLeaseSnapshot
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RateLeaseSnapshot
impl Debug for RateLeaseSnapshot
Source§impl<'de> Deserialize<'de> for RateLeaseSnapshot
impl<'de> Deserialize<'de> for RateLeaseSnapshot
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for RateLeaseSnapshot
impl PartialEq for RateLeaseSnapshot
Source§impl Serialize for RateLeaseSnapshot
impl Serialize for RateLeaseSnapshot
impl StructuralPartialEq for RateLeaseSnapshot
Auto Trait Implementations§
impl Freeze for RateLeaseSnapshot
impl RefUnwindSafe for RateLeaseSnapshot
impl Send for RateLeaseSnapshot
impl Sync for RateLeaseSnapshot
impl Unpin for RateLeaseSnapshot
impl UnsafeUnpin for RateLeaseSnapshot
impl UnwindSafe for RateLeaseSnapshot
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreCreates a shared type from an unshared type.