Documentation ¶
Index ¶
Constants ¶
const ( // Special attribute key used by Ops Agent prometheus receiver to denote untyped // prometheus metric. Internal use only. GCPOpsAgentUntypedMetricKey = "prometheus_untyped_metric" )
Variables ¶
This section is empty.
Functions ¶
func AddScopeInfoMetric ¶ added in v0.35.0
AddScopeInfoMetric adds the otel_scope_info metric to a Metrics slice as specified in https://github.com/open-telemetry/opentelemetry-specification/blob/v1.16.0/specification/compatibility/prometheus_and_openmetrics.md#instrumentation-scope-1 It also updates all other metrics with the corresponding scope_name and scope_version attributes, if they are present.
func AddTargetInfoMetric ¶ added in v0.35.0
AddTargetInfoMetric inserts target_info for each resource. First, it extracts the target_info metric from each ResourceMetric associated with the input pmetric.Metrics and inserts it into a new ScopeMetric for that resource, as specified in https://github.com/open-telemetry/opentelemetry-specification/blob/v1.16.0/specification/compatibility/prometheus_and_openmetrics.md#resource-attributes-1
func AddUntypedMetrics ¶ added in v0.41.0
AddUntypedMetrics looks for any Gauge data point with the special Ops Agent untyped metric attribute and duplicates that data point to a matching Sum.
func MapToPrometheusTarget ¶
func MapToPrometheusTarget(res pcommon.Resource) *monitoredrespb.MonitoredResource
Types ¶
This section is empty.