Struct Metric Measurement
Generated from cargo doc --no-deps -p nemo-relay -p nemo-relay-adaptive -p nemo-relay-pii-redaction -p nemo-relay-ffi -p nemo-relay-types -p nemo-relay-plugin -p nemo-relay-worker-proto -p nemo-relay-worker.
pub struct MetricMeasurement {
pub name: String,
pub kind: MetricKind,
pub value_type: MetricValueType,
pub value: Json,
pub unit: Option<String>,
pub description: Option<String>,
pub attributes: Option<Json>,
pub boundaries: Option<Vec<f64>>,
}
One recording operation in a Relay metric mark.
Fields
name: String
OpenTelemetry instrument name.
kind: MetricKind
Instrument kind used to record the value.
value_type: MetricValueType
Explicit numeric representation of value.
value: Json
Numeric recording value.
unit: Option<String>
Optional OpenTelemetry instrument unit.
description: Option<String>
Optional OpenTelemetry instrument description.
attributes: Option<Json>
Optional low-cardinality OpenTelemetry attributes object.
boundaries: Option<Vec<f64>>
Optional explicit histogram bucket boundaries.
Implementations
impl MetricMeasurement
impl MetricMeasurement
builder
pub fn builder() -> MetricMeasurementBuilder<((), (), (), (), (), (), (), ())>
Create a builder for building MetricMeasurement. On the builder, call .name(...), .kind(...), .value_type(...), .value(...), .unit(...)(optional), .description(...)(optional), .attributes(...)(optional), .boundaries(...)(optional) to set the values of the fields. Finally, call .build() to create the instance of MetricMeasurement.
Trait Implementations
impl Clone for MetricMeasurement
impl Clone for MetricMeasurement
clone
fn clone(&self) -> MetricMeasurement
clone_from
fn clone_from(&mut self, source: &Self)
impl Debug for MetricMeasurement
impl Debug for MetricMeasurement
fmt
fn fmt(&self, f: &mut Formatter<'_>) -> Result
impl<'de> Deserialize<'de> for MetricMeasurement
impl<'de> Deserialize<'de> for MetricMeasurement
deserialize
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl PartialEq for MetricMeasurement
impl PartialEq for MetricMeasurement
eq
fn eq(&self, other: &MetricMeasurement) -> bool
ne
fn ne(&self, other: &Rhs) -> bool
impl Serialize for MetricMeasurement
impl Serialize for MetricMeasurement
serialize
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>where
__S: Serializer,
impl TryFrom<&MetricMeasurement> for ValidatedMetricMeasurement
impl TryFrom<&MetricMeasurement> for ValidatedMetricMeasurement
Error
type Error = MetricValidationError
try_from
fn try_from(wire: &MetricMeasurement) -> Result<Self, Self::Error>
impl StructuralPartialEq for MetricMeasurement
impl StructuralPartialEq for MetricMeasurement