Documentation ¶
Index ¶
- func Metric(id string, dps ...pmetric.NumberDataPoint) pmetric.Metric
- func NewMetrics(resourceIDs, scopeIDs, metricIDs, dataPointIDs string) pmetric.Metrics
- func NewMetricsFromOpts(resources ...pmetric.ResourceMetrics) pmetric.Metrics
- func NumberDataPoint(id string) pmetric.NumberDataPoint
- func Resource(id string, scopes ...pmetric.ScopeMetrics) pmetric.ResourceMetrics
- func Scope(id string, metrics ...pmetric.Metric) pmetric.ScopeMetrics
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Metric ¶ added in v0.114.0
func Metric(id string, dps ...pmetric.NumberDataPoint) pmetric.Metric
func NewMetrics ¶
NewMetrics returns a pmetric.Metrics with a uniform structure where resources, scopes, metrics, and datapoints are identical across all instances, except for one identifying field.
Identifying fields: - Resources have an attribute called "resourceName" with a value of "resourceN". - Scopes have a name with a value of "scopeN". - Metrics have a name with a value of "metricN" and a single time series of data points. - DataPoints have an attribute "dpName" with a value of "dpN".
Example: NewMetrics("AB", "XYZ", "MN", "1234") returns:
resourceA, resourceB each with scopeX, scopeY, scopeZ each with metricM, metricN each with dp1, dp2, dp3, dp4
Each byte in the input string is a unique ID for the corresponding element.
func NewMetricsFromOpts ¶ added in v0.114.0
func NewMetricsFromOpts(resources ...pmetric.ResourceMetrics) pmetric.Metrics
func NumberDataPoint ¶ added in v0.114.0
func NumberDataPoint(id string) pmetric.NumberDataPoint
func Resource ¶ added in v0.114.0
func Resource(id string, scopes ...pmetric.ScopeMetrics) pmetric.ResourceMetrics
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.