otlpexporter

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2020 License: Apache-2.0 Imports: 20 Imported by: 47

README

OTLP Exporter

Exports traces and/or metrics via gRPC using OpenTelemetry format.

The following settings are required:

The following settings can be optionally configured:

  • insecure (default = false): whether to enable client transport security for the exporter's gRPC connection. See grpc.WithInsecure().
  • ca_file path to the CA cert. For a client this verifies the server certificate. Should only be used if insecure is set to true.
  • cert_file path to the TLS cert to use for TLS required connections. Should only be used if insecure is set to true.
  • key_file path to the TLS key to use for TLS required connections. Should only be used if insecure is set to true.
  • compression compression key for supported compression types within the collector. Currently, the only supported mode is gzip.
  • headers the headers associated with gRPC requests.
  • keepalive keepalive parameters for client gRPC. See grpc.WithKeepaliveParams().
  • reconnection_delay: time period between each reconnection performed by the exporter.
  • insecure whether to enable client transport security for the exporter's gRPC connection. See grpc.WithInsecure().
  • balancer_name(default = pick_first): Sets the balancer in grpclb_policy to discover the servers. See grpc loadbalancing example.
  • timeout (default = 5s): Is the timeout for every attempt to send data to the backend.
  • retry_on_failure
    • enabled (default = true)
    • initial_interval (default = 5s): Time to wait after the first failure before retrying; ignored if enabled is false
    • max_interval (default = 30s): Is the upper bound on backoff; ignored if enabled is false
    • max_elapsed_time (default = 120s): Is the maximum amount of time spent trying to send a batch; ignored if enabled is false
  • sending_queue
    • enabled (default = false)
    • num_consumers (default = 10): Number of consumers that dequeue batches; ignored if enabled is false
    • queue_size (default = 5000): Maximum number of batches kept in memory before data; ignored if enabled is false; User should calculate this as num_seconds * requests_per_second where:
      • num_seconds is the number of seconds to buffer in case of a backend outage
      • requests_per_second is the average number of requests per seconds.

Example:

exporters:
  otlp:
    endpoint: otelcol2:55680
    reconnection_delay: 60s
    insecure: true

The full list of settings exposed for this exporter are documented here with detailed sample configurations here.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewFactory added in v0.7.0

func NewFactory() component.ExporterFactory

NewFactory creates a factory for OTLP exporter.

Types

type Config

type Config struct {
	configmodels.ExporterSettings  `mapstructure:",squash"` // squash ensures fields are correctly decoded in embedded struct.
	exporterhelper.TimeoutSettings `mapstructure:",squash"` // squash ensures fields are correctly decoded in embedded struct.
	exporterhelper.QueueSettings   `mapstructure:"sending_queue"`
	exporterhelper.RetrySettings   `mapstructure:"retry_on_failure"`

	configgrpc.GRPCClientSettings `mapstructure:",squash"` // squash ensures fields are correctly decoded in embedded struct.
}

Config defines configuration for OpenCensus exporter.

Jump to

Keyboard shortcuts

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