#[non_exhaustive]pub struct DispatchCounts {
pub shed: u64,
pub acks: u64,
pub unmatched: u64,
pub unsupported: u64,
pub malformed: u64,
pub merged: u64,
pub identity: u64,
pub draining: u64,
}Expand description
What a dispatcher has refused, shed or could not place.
The same shape as sipx_transport::ShedCounts and for the same reason (T-19): loss that
cannot be counted from outside is loss nobody is told about.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.shed: u64Requests answered 503 because the call they belong to was not reading its inbox.
acks: u64ACKs that could not be delivered — to a full inbox, or to no call at all.
Counted apart because an ACK cannot be refused: SIP has no response to one, so nothing retransmits it after Timer H and the dialog it would have completed is not reaped unless RFC 4028 session timers happen to be running. This is the one that leaks calls.
unmatched: u64Requests answered 481 Call/Transaction Does Not Exist.
Two kinds, counted together because they are one fact — something named a dialog or a transaction this endpoint does not have: an in-dialog request for no live call (RFC 3261 §12.2.2), and a CANCEL matching no pending INVITE transaction (§9.2).
unsupported: u64Out-of-dialog requests answered 405 Method Not Allowed (RFC 3261 §8.2.1).
malformed: u64Requests answered 400 Bad Request for naming no dialog at all — no Call-ID, or no
From tag, both of which RFC 3261 §8.1.1 makes mandatory.
merged: u64INVITEs answered 482 Loop Detected as merged requests (RFC 3261 §8.2.2.2).
identity: u64Initial INVITEs refused by the caller-selected authenticated-identity policy.
draining: u64Valid new work refused because graceful drain intentionally closed admission.
Implementations§
Source§impl DispatchCounts
impl DispatchCounts
Sourcepub fn total(self) -> u64
pub fn total(self) -> u64
Everything the dispatcher did not deliver, of every kind.
Every field above, and every refusal the dispatcher makes is on one of them. That is a
property worth stating rather than assuming: two of these fields exist because the first
version of this type had four, and the 400 and 482 branches moved no counter at all —
two refusals invisible to the counters this story added to make loss visible.
Trait Implementations§
Source§impl Clone for DispatchCounts
impl Clone for DispatchCounts
Source§fn clone(&self) -> DispatchCounts
fn clone(&self) -> DispatchCounts
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DispatchCounts
impl Debug for DispatchCounts
Source§impl Default for DispatchCounts
impl Default for DispatchCounts
Source§fn default() -> DispatchCounts
fn default() -> DispatchCounts
Source§impl PartialEq for DispatchCounts
impl PartialEq for DispatchCounts
Source§fn eq(&self, other: &DispatchCounts) -> bool
fn eq(&self, other: &DispatchCounts) -> bool
self and other values to be equal, and is used by ==.impl Copy for DispatchCounts
impl Eq for DispatchCounts
impl StructuralPartialEq for DispatchCounts
Auto Trait Implementations§
impl Freeze for DispatchCounts
impl RefUnwindSafe for DispatchCounts
impl Send for DispatchCounts
impl Sync for DispatchCounts
impl Unpin for DispatchCounts
impl UnsafeUnpin for DispatchCounts
impl UnwindSafe for DispatchCounts
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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>
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>
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 more