Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,24 @@
/// storage, OR can be embedded by other protocols that transfer OTLP metrics
/// data but do not implement the OTLP protocol.
///
/// MetricsData
/// └─── ResourceMetrics
/// ├── Resource
/// ├── SchemaURL
/// └── ScopeMetrics
/// ├── Scope
/// ├── SchemaURL
/// └── Metric
/// ├── Name
/// ├── Description
/// ├── Unit
/// └── data
/// ├── Gauge
/// ├── Sum
/// ├── Histogram
/// ├── ExponentialHistogram
/// └── Summary
///
/// The main difference between this message and collector protocol is that
/// in this message there will not be any "control" or "metadata" specific to
/// OTLP protocol.
Expand Down Expand Up @@ -71,7 +89,6 @@ pub struct ScopeMetrics {
///
/// <https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/data-model.md>
///
///
/// The data model and relation between entities is shown in the
/// diagram below. Here, "DataPoint" is the term used to refer to any
/// one of the specific data point value types, and "points" is the term used
Expand All @@ -83,7 +100,7 @@ pub struct ScopeMetrics {
/// - DataPoint contains timestamps, attributes, and one of the possible value type
/// fields.
///
/// Metric
/// Metric
/// +------------+
/// |name |
/// |description |
Expand Down Expand Up @@ -277,6 +294,9 @@ pub struct ExponentialHistogram {
/// data type. These data points cannot always be merged in a meaningful way.
/// While they can be useful in some applications, histogram data points are
/// recommended for new applications.
/// Summary metrics do not have an aggregation temporality field. This is
/// because the count and sum fields of a SummaryDataPoint are assumed to be
/// cumulative values.
#[cfg_attr(feature = "with-schemars", derive(schemars::JsonSchema))]
#[cfg_attr(feature = "with-serde", derive(serde::Serialize, serde::Deserialize))]
#[cfg_attr(feature = "with-serde", serde(rename_all = "camelCase"))]
Expand Down Expand Up @@ -587,7 +607,8 @@ pub mod exponential_histogram_data_point {
}
}
/// SummaryDataPoint is a single data point in a timeseries that describes the
/// time-varying values of a Summary metric.
/// time-varying values of a Summary metric. The count and sum fields represent
/// cumulative values.
#[cfg_attr(feature = "with-schemars", derive(schemars::JsonSchema))]
#[cfg_attr(feature = "with-serde", derive(serde::Serialize, serde::Deserialize))]
#[cfg_attr(feature = "with-serde", serde(rename_all = "camelCase"))]
Expand Down
Loading