otel

package
v0.13.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Overview

Package otel provides an OpenTelemetry surfacer for Cloudprober. It can export metrics to OpenTelemetry Collector over gRPC or HTTP.

This surfacer holds the incoming EventMetrics in memory and periodically (default: 10s) exports them the configured HTTP or gRPC endpoint.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OtelSurfacer

type OtelSurfacer struct {
	// contains filtered or unexported fields
}

OtelSurfacer implements OpenTelemetry surfacer for Cloudprober.

func New

New returns a prometheus surfacer based on the config provided. It sets up a goroutine to process both the incoming EventMetrics and the web requests for the URL handler /metrics.

func (*OtelSurfacer) Produce

func (*OtelSurfacer) Write

func (os *OtelSurfacer) Write(_ context.Context, em *metrics.EventMetrics)

record processes the incoming EventMetrics and updates the in-memory otel metrics database.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL