Back to godoc.org
go.opentelemetry.io/collector/processor/resourceprocessor

package resourceprocessor

v0.4.0
Latest Go to latest
Published: Jun 16, 2020 | License: Apache-2.0 | Module: go.opentelemetry.io/collector

Overview

Package resourceprocessor implements a processor for specifying resource labels to be added to OpenCensus trace data and metrics data.

Index

type Config

type Config struct {
	configmodels.ProcessorSettings `mapstructure:",squash"`
	// ResourceType overrides the original resource type.
	ResourceType string `mapstructure:"type"`
	// Labels specify static labels to be added to resource.
	// In case of a conflict the label will be overridden.
	Labels map[string]string `mapstructure:"labels"`
}

Config defines configuration for Resource processor.

type Factory

type Factory struct {
}

Factory is the factory for OpenCensus exporter.

func (Factory) CreateDefaultConfig

func (Factory) CreateDefaultConfig() configmodels.Processor

CreateDefaultConfig creates the default configuration for processor.

func (Factory) CreateMetricsProcessor

func (Factory) CreateMetricsProcessor(logger *zap.Logger, nextConsumer consumer.MetricsConsumerOld, cfg configmodels.Processor) (component.MetricsProcessorOld, error)

CreateMetricsProcessor creates a metrics processor based on this config.

func (Factory) CreateTraceProcessor

func (Factory) CreateTraceProcessor(logger *zap.Logger, nextConsumer consumer.TraceConsumerOld, cfg configmodels.Processor) (component.TraceProcessorOld, error)

CreateTraceProcessor creates a trace processor based on this config.

func (Factory) Type

func (Factory) Type() configmodels.Type

Type gets the type of the Option config created by this factory.

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
f or F : Jump to identifier