pub struct CountersSnapshot {
pub requests: u64,
pub unauthorized: u64,
pub throttled: u64,
pub failed: u64,
pub duration_us: u64,
}Expand description
One reading of Counters, taken field by field.
The fields are not read atomically with respect to each other, which is the ordinary bargain for a metrics scrape: a counter may be one request further along than the one beside it. An alert on a rate over a scrape interval cannot see the difference.
Fields§
§requests: u64Requests served, whatever their status.
Requests refused as unauthenticated or forbidden (401, 403).
throttled: u64Requests refused by a rate limit or a quota (429).
failed: u64Requests the node failed to serve (5xx, and I/O errors mid-write).
duration_us: u64Total time spent serving, microseconds. With requests, this is
the pair an average-latency alert needs.
Trait Implementations§
Source§impl Clone for CountersSnapshot
impl Clone for CountersSnapshot
Source§fn clone(&self) -> CountersSnapshot
fn clone(&self) -> CountersSnapshot
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 CountersSnapshot
impl Debug for CountersSnapshot
impl Copy for CountersSnapshot
Auto Trait Implementations§
impl Freeze for CountersSnapshot
impl RefUnwindSafe for CountersSnapshot
impl Send for CountersSnapshot
impl Sync for CountersSnapshot
impl Unpin for CountersSnapshot
impl UnsafeUnpin for CountersSnapshot
impl UnwindSafe for CountersSnapshot
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