pub struct TraceStats {Show 17 fields
pub buffer_stats: Vec<BufferStats>,
pub chunk_payload_histogram_def: Vec<i64>,
pub writer_stats: Vec<WriterStats>,
pub producers_connected: Option<u32>,
pub producers_seen: Option<u64>,
pub data_sources_registered: Option<u32>,
pub data_sources_seen: Option<u64>,
pub tracing_sessions: Option<u32>,
pub total_buffers: Option<u32>,
pub chunks_discarded: Option<u64>,
pub patches_discarded: Option<u64>,
pub invalid_packets: Option<u64>,
pub filter_stats: Option<FilterStats>,
pub flushes_requested: Option<u64>,
pub flushes_succeeded: Option<u64>,
pub flushes_failed: Option<u64>,
pub final_flush_outcome: Option<i32>,
}
Expand description
Statistics for the internals of the tracing service.
Next id: 19.
Fields§
§buffer_stats: Vec<BufferStats>
Stats for the TraceBuffer(s) of the current trace session.
chunk_payload_histogram_def: Vec<i64>
The thresholds of each the writer_stats
histogram buckets. This is
emitted only once as all WriterStats share the same bucket layout.
This field has the same cardinality of the
writer_stats.chunk_payload_histogram_{counts,sum}
- 1.
(The -1 is because the last overflow bucket is not reported in the _def).
An array of values [10, 100, 1000] in the _def array means that there are
four buckets (3 + the implicit overflow bucket):
[0]: x <= 10; [1]: 100 < x <= 1000; [2]: 1000 < x <= 1000; [3]: x > 1000.
writer_stats: Vec<WriterStats>
§producers_connected: Option<u32>
Num. producers connected (whether they are involved in the current tracing session or not).
producers_seen: Option<u64>
Num. producers ever seen for all trace sessions since startup (it’s a good proxy for inferring num. producers crashed / killed).
data_sources_registered: Option<u32>
Num. data sources registered for all trace sessions.
data_sources_seen: Option<u64>
Num. data sources ever seen for all trace sessions since startup.
tracing_sessions: Option<u32>
Num. concurrently active tracing sessions.
total_buffers: Option<u32>
Num. buffers for all tracing session (not just the current one). This will be >= buffer_stats.size(), because the latter is only about the current session.
chunks_discarded: Option<u64>
Num. chunks that were discarded by the service before attempting to commit them to a buffer, e.g. because the producer specified an invalid buffer ID.
patches_discarded: Option<u64>
Num. patches that were discarded by the service before attempting to apply them to a buffer, e.g. because the producer specified an invalid buffer ID.
invalid_packets: Option<u64>
Packets that failed validation of the TrustedPacket. If this is > 0, there is a bug in the producer.
filter_stats: Option<FilterStats>
§flushes_requested: Option<u64>
Count of Flush() requests (either from the Consumer, or self-induced periodic flushes). The final Flush() is also included in the count.
flushes_succeeded: Option<u64>
The count of the Flush() requests that were completed successfully.
In a well behaving trace this should always be == flush_requests
.
flushes_failed: Option<u64>
The count of the Flush() requests that failed (in most timed out). In a well behaving trace this should always be == 0.
final_flush_outcome: Option<i32>
Implementations§
Source§impl TraceStats
impl TraceStats
Sourcepub fn producers_connected(&self) -> u32
pub fn producers_connected(&self) -> u32
Returns the value of producers_connected
, or the default value if producers_connected
is unset.
Sourcepub fn producers_seen(&self) -> u64
pub fn producers_seen(&self) -> u64
Returns the value of producers_seen
, or the default value if producers_seen
is unset.
Sourcepub fn data_sources_registered(&self) -> u32
pub fn data_sources_registered(&self) -> u32
Returns the value of data_sources_registered
, or the default value if data_sources_registered
is unset.
Sourcepub fn data_sources_seen(&self) -> u64
pub fn data_sources_seen(&self) -> u64
Returns the value of data_sources_seen
, or the default value if data_sources_seen
is unset.
Sourcepub fn tracing_sessions(&self) -> u32
pub fn tracing_sessions(&self) -> u32
Returns the value of tracing_sessions
, or the default value if tracing_sessions
is unset.
Sourcepub fn total_buffers(&self) -> u32
pub fn total_buffers(&self) -> u32
Returns the value of total_buffers
, or the default value if total_buffers
is unset.
Sourcepub fn chunks_discarded(&self) -> u64
pub fn chunks_discarded(&self) -> u64
Returns the value of chunks_discarded
, or the default value if chunks_discarded
is unset.
Sourcepub fn patches_discarded(&self) -> u64
pub fn patches_discarded(&self) -> u64
Returns the value of patches_discarded
, or the default value if patches_discarded
is unset.
Sourcepub fn invalid_packets(&self) -> u64
pub fn invalid_packets(&self) -> u64
Returns the value of invalid_packets
, or the default value if invalid_packets
is unset.
Sourcepub fn flushes_requested(&self) -> u64
pub fn flushes_requested(&self) -> u64
Returns the value of flushes_requested
, or the default value if flushes_requested
is unset.
Sourcepub fn flushes_succeeded(&self) -> u64
pub fn flushes_succeeded(&self) -> u64
Returns the value of flushes_succeeded
, or the default value if flushes_succeeded
is unset.
Sourcepub fn flushes_failed(&self) -> u64
pub fn flushes_failed(&self) -> u64
Returns the value of flushes_failed
, or the default value if flushes_failed
is unset.
Sourcepub fn final_flush_outcome(&self) -> FinalFlushOutcome
pub fn final_flush_outcome(&self) -> FinalFlushOutcome
Returns the enum value of final_flush_outcome
, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_final_flush_outcome(&mut self, value: FinalFlushOutcome)
pub fn set_final_flush_outcome(&mut self, value: FinalFlushOutcome)
Sets final_flush_outcome
to the provided enum value.
Trait Implementations§
Source§impl Clone for TraceStats
impl Clone for TraceStats
Source§fn clone(&self) -> TraceStats
fn clone(&self) -> TraceStats
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for TraceStats
impl Debug for TraceStats
Source§impl Default for TraceStats
impl Default for TraceStats
Source§impl Message for TraceStats
impl Message for TraceStats
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
.Source§impl PartialEq for TraceStats
impl PartialEq for TraceStats
impl StructuralPartialEq for TraceStats
Auto Trait Implementations§
impl Freeze for TraceStats
impl RefUnwindSafe for TraceStats
impl Send for TraceStats
impl Sync for TraceStats
impl Unpin for TraceStats
impl UnwindSafe for TraceStats
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,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)