pub struct TraceMetric {
pub timestamp: Annotated<Timestamp>,
pub trace_id: Annotated<TraceId>,
pub span_id: Annotated<SpanId>,
pub name: Annotated<String>,
pub ty: Annotated<MetricType>,
pub unit: Annotated<MetricUnit>,
pub value: Annotated<Value>,
pub attributes: Annotated<Attributes>,
pub other: Object<Value>,
}
Fields§
§timestamp: Annotated<Timestamp>
Timestamp when the metric was created.
trace_id: Annotated<TraceId>
The ID of the trace the metric belongs to.
span_id: Annotated<SpanId>
The Span this metric belongs to.
name: Annotated<String>
The metric name.
ty: Annotated<MetricType>
The metric type.
unit: Annotated<MetricUnit>
The metric unit.
value: Annotated<Value>
The metric value.
Should be constrained to a number.
attributes: Annotated<Attributes>
Arbitrary attributes on a metric.
other: Object<Value>
Additional arbitrary fields for forwards compatibility.
Trait Implementations§
Source§impl Clone for TraceMetric
impl Clone for TraceMetric
Source§fn clone(&self) -> TraceMetric
fn clone(&self) -> TraceMetric
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 TraceMetric
impl Debug for TraceMetric
Source§impl Default for TraceMetric
impl Default for TraceMetric
Source§fn default() -> TraceMetric
fn default() -> TraceMetric
Returns the “default value” for a type. Read more
Source§impl Empty for TraceMetric
impl Empty for TraceMetric
Source§impl FromObjectRef for TraceMetric
impl FromObjectRef for TraceMetric
Source§fn from_object_ref(__obj: &mut Object<Value>) -> Self
fn from_object_ref(__obj: &mut Object<Value>) -> Self
Creates a meta structure from key value pairs. Read more
Source§impl FromValue for TraceMetric
impl FromValue for TraceMetric
Source§fn from_value(__value: Annotated<Value>) -> Annotated<Self>
fn from_value(__value: Annotated<Value>) -> Annotated<Self>
Creates a meta structure from an annotated boxed value.
Source§impl Getter for TraceMetric
impl Getter for TraceMetric
Source§impl IntoObjectRef for TraceMetric
impl IntoObjectRef for TraceMetric
Source§fn into_object_ref(self, __map: &mut Object<Value>)
fn into_object_ref(self, __map: &mut Object<Value>)
Boxes the meta structure back into an object of values. Read more
Source§impl IntoValue for TraceMetric
impl IntoValue for TraceMetric
Source§fn into_value(self) -> Value
fn into_value(self) -> Value
Boxes the meta structure back into a value.
Source§fn serialize_payload<S>(
&self,
__serializer: S,
__behavior: SkipSerialization,
) -> Result<S::Ok, S::Error>where
Self: Sized,
S: Serializer,
fn serialize_payload<S>(
&self,
__serializer: S,
__behavior: SkipSerialization,
) -> Result<S::Ok, S::Error>where
Self: Sized,
S: Serializer,
Efficiently serializes the payload directly.
Source§fn extract_child_meta(&self) -> MetaMapwhere
Self: Sized,
fn extract_child_meta(&self) -> MetaMapwhere
Self: Sized,
Extracts children meta map out of a value.
§fn extract_meta_tree(value: &Annotated<Self>) -> MetaTreewhere
Self: Sized,
fn extract_meta_tree(value: &Annotated<Self>) -> MetaTreewhere
Self: Sized,
Extracts the meta tree out of annotated value. Read more
Source§impl PartialEq for TraceMetric
impl PartialEq for TraceMetric
Source§impl ProcessValue for TraceMetric
impl ProcessValue for TraceMetric
Source§fn value_type(&self) -> EnumSet<ValueType>
fn value_type(&self) -> EnumSet<ValueType>
Returns the type of the value.
Source§fn process_value<P>(
&mut self,
__meta: &mut Meta,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
fn process_value<P>(
&mut self,
__meta: &mut Meta,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
Executes a processor on this value.
Source§fn process_child_values<P>(
&mut self,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
fn process_child_values<P>(
&mut self,
__processor: &mut P,
__state: &ProcessingState<'_>,
) -> ProcessingResultwhere
P: Processor,
Recurses into children of this value.
impl StructuralPartialEq for TraceMetric
Auto Trait Implementations§
impl Freeze for TraceMetric
impl RefUnwindSafe for TraceMetric
impl Send for TraceMetric
impl Sync for TraceMetric
impl Unpin for TraceMetric
impl UnwindSafe for TraceMetric
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