pub struct ProtocolMetrics {Show 13 fields
pub crypto_operations: AtomicU64,
pub key_cache_hits: AtomicU64,
pub key_cache_misses: AtomicU64,
pub messages_processed: AtomicU64,
pub active_connections: AtomicU64,
pub connection_errors: AtomicU64,
pub route_cache_hits: AtomicU64,
pub consensus_rounds: AtomicU64,
pub dag_updates: AtomicU64,
pub node_count: AtomicU64,
pub memory_usage: AtomicU64,
pub thread_count: AtomicU64,
pub queue_depth: AtomicU64,
/* private fields */
}
Expand description
Performance metrics for the QuDAG protocol
Fields§
§crypto_operations: AtomicU64
§key_cache_hits: AtomicU64
§key_cache_misses: AtomicU64
§messages_processed: AtomicU64
§active_connections: AtomicU64
§connection_errors: AtomicU64
§route_cache_hits: AtomicU64
§consensus_rounds: AtomicU64
§dag_updates: AtomicU64
§node_count: AtomicU64
§memory_usage: AtomicU64
§thread_count: AtomicU64
§queue_depth: AtomicU64
Implementations§
Source§impl ProtocolMetrics
impl ProtocolMetrics
Sourcepub fn record_crypto_op(&self, _latency: Duration)
pub fn record_crypto_op(&self, _latency: Duration)
Record cryptographic operation
Sourcepub fn record_message(&self, _latency: Duration)
pub fn record_message(&self, _latency: Duration)
Record message processing
Sourcepub fn record_consensus(&self, _latency: Duration)
pub fn record_consensus(&self, _latency: Duration)
Record consensus round
Sourcepub fn update_resources(&self, memory: u64, threads: u64, queue: u64)
pub fn update_resources(&self, memory: u64, threads: u64, queue: u64)
Update resource metrics
Sourcepub fn get_summary(&self) -> PerformanceSummary
pub fn get_summary(&self) -> PerformanceSummary
Get performance summary
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for ProtocolMetrics
impl !RefUnwindSafe for ProtocolMetrics
impl Send for ProtocolMetrics
impl Sync for ProtocolMetrics
impl Unpin for ProtocolMetrics
impl !UnwindSafe for ProtocolMetrics
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> 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 more