pub enum TraceEntry {
Request {
correlation_id: String,
timestamp: String,
method: String,
params: Option<Value>,
span_id: Option<String>,
},
Response {
correlation_id: String,
timestamp: String,
method: String,
duration_ms: f64,
result: Option<Value>,
error: Option<Value>,
span_id: Option<String>,
},
SpanStart {
span_id: String,
parent_span_id: Option<String>,
name: String,
timestamp: String,
},
SpanEnd {
span_id: String,
timestamp: String,
duration_ms: f64,
error: Option<String>,
},
Log {
timestamp: String,
level: TraceLevel,
message: String,
span_id: Option<String>,
data: Option<Value>,
},
Metric {
timestamp: String,
name: String,
value: f64,
unit: Option<String>,
span_id: Option<String>,
},
}Expand description
Entry type in a trace.
Variants§
Request
A request was sent.
Fields
Response
A response was received.
Fields
SpanStart
A span was started.
SpanEnd
A span was ended.
Log
A log message.
Fields
§
level: TraceLevelMetric
A metric measurement.
Trait Implementations§
Source§impl Clone for TraceEntry
impl Clone for TraceEntry
Source§fn clone(&self) -> TraceEntry
fn clone(&self) -> TraceEntry
Returns a duplicate of the value. Read more
1.0.0 · 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 TraceEntry
impl Debug for TraceEntry
Source§impl<'de> Deserialize<'de> for TraceEntry
impl<'de> Deserialize<'de> for TraceEntry
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
Auto Trait Implementations§
impl Freeze for TraceEntry
impl RefUnwindSafe for TraceEntry
impl Send for TraceEntry
impl Sync for TraceEntry
impl Unpin for TraceEntry
impl UnwindSafe for TraceEntry
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,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, _span: NoopSpan) -> Self
fn instrument(self, _span: NoopSpan) -> Self
Instruments this future with a span (no-op when disabled).
Source§fn in_current_span(self) -> Self
fn in_current_span(self) -> Self
Instruments this future with the current span (no-op when disabled).