@@ -29,6 +29,24 @@ option go_package = "go.opentelemetry.io/proto/otlp/metrics/v1";
2929// storage, OR can be embedded by other protocols that transfer OTLP metrics
3030// data but do not implement the OTLP protocol.
3131//
32+ // MetricsData
33+ // └─── ResourceMetrics
34+ // ├── Resource
35+ // ├── SchemaURL
36+ // └── ScopeMetrics
37+ // ├── Scope
38+ // ├── SchemaURL
39+ // └── Metric
40+ // ├── Name
41+ // ├── Description
42+ // ├── Unit
43+ // └── data
44+ // ├── Gauge
45+ // ├── Sum
46+ // ├── Histogram
47+ // ├── ExponentialHistogram
48+ // └── Summary
49+ //
3250// The main difference between this message and collector protocol is that
3351// in this message there will not be any "control" or "metadata" specific to
3452// OTLP protocol.
@@ -56,7 +74,8 @@ message ResourceMetrics {
5674 repeated ScopeMetrics scope_metrics = 2 ;
5775
5876 // The Schema URL, if known. This is the identifier of the Schema that the resource data
59- // is recorded in. To learn more about Schema URL see
77+ // is recorded in. Notably, the last part of the URL path is the version number of the
78+ // schema: http[s]://server[:port]/path/<version>. To learn more about Schema URL see
6079 // https://opentelemetry.io/docs/specs/otel/schemas/#schema-url
6180 // This schema_url applies to the data in the "resource" field. It does not apply
6281 // to the data in the "scope_metrics" field which have their own schema_url field.
@@ -74,7 +93,8 @@ message ScopeMetrics {
7493 repeated Metric metrics = 2 ;
7594
7695 // The Schema URL, if known. This is the identifier of the Schema that the metric data
77- // is recorded in. To learn more about Schema URL see
96+ // is recorded in. Notably, the last part of the URL path is the version number of the
97+ // schema: http[s]://server[:port]/path/<version>. To learn more about Schema URL see
7898 // https://opentelemetry.io/docs/specs/otel/schemas/#schema-url
7999 // This schema_url applies to all metrics in the "metrics" field.
80100 string schema_url = 3 ;
@@ -85,7 +105,6 @@ message ScopeMetrics {
85105//
86106// https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/data-model.md
87107//
88- //
89108// The data model and relation between entities is shown in the
90109// diagram below. Here, "DataPoint" is the term used to refer to any
91110// one of the specific data point value types, and "points" is the term used
@@ -97,7 +116,7 @@ message ScopeMetrics {
97116// - DataPoint contains timestamps, attributes, and one of the possible value type
98117// fields.
99118//
100- // Metric
119+ // Metric
101120// +------------+
102121// |name |
103122// |description |
@@ -251,6 +270,9 @@ message ExponentialHistogram {
251270// data type. These data points cannot always be merged in a meaningful way.
252271// While they can be useful in some applications, histogram data points are
253272// recommended for new applications.
273+ // Summary metrics do not have an aggregation temporality field. This is
274+ // because the count and sum fields of a SummaryDataPoint are assumed to be
275+ // cumulative values.
254276message Summary {
255277 repeated SummaryDataPoint data_points = 1 ;
256278}
@@ -589,7 +611,8 @@ message ExponentialHistogramDataPoint {
589611}
590612
591613// SummaryDataPoint is a single data point in a timeseries that describes the
592- // time-varying values of a Summary metric.
614+ // time-varying values of a Summary metric. The count and sum fields represent
615+ // cumulative values.
593616message SummaryDataPoint {
594617 reserved 1 ;
595618
0 commit comments