host_info

package
v0.40.5 Latest Latest
Warning

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

Go to latest
Published: May 15, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Overview

Package host_info provides an otelcol.connector.host_info component.

Index

Constants

This section is empty.

Variables

View Source
var DefaultArguments = Arguments{
	HostIdentifiers:      []string{"host.id"},
	MetricsFlushInterval: 60 * time.Second,
}

DefaultArguments holds default settings for Arguments.

Functions

func NewFactory

func NewFactory() connector.Factory

Types

type Arguments

type Arguments struct {
	HostIdentifiers      []string      `river:"host_identifiers,attr,optional"`
	MetricsFlushInterval time.Duration `river:"metrics_flush_interval,attr,optional"`

	// Output configures where to send processed data. Required.
	Output *otelcol.ConsumerArguments `river:"output,block"`
}

Arguments configures the otelcol.connector.host_info component.

func (Arguments) ConnectorType

func (Arguments) ConnectorType() int

ConnectorType() int implements connector.Arguments.

func (Arguments) Convert

func (args Arguments) Convert() (otelcomponent.Config, error)

Convert implements connector.Arguments.

func (Arguments) Exporters

Exporters implements connector.Arguments.

func (Arguments) Extensions

func (args Arguments) Extensions() map[otelcomponent.ID]otelextension.Extension

Extensions implements connector.Arguments.

func (Arguments) NextConsumers

func (args Arguments) NextConsumers() *otelcol.ConsumerArguments

NextConsumers implements connector.Arguments.

func (*Arguments) SetToDefault

func (args *Arguments) SetToDefault()

SetToDefault implements river.Defaulter.

func (*Arguments) Validate

func (args *Arguments) Validate() error

Validate implements river.Validator.

type Config

type Config struct {
	// HostIdentifiers defines the list of resource attributes used to derive
	// a unique `grafana.host.id` value. In most cases, this should be [ "host.id" ]
	HostIdentifiers      []string      `mapstructure:"host_identifiers"`
	MetricsFlushInterval time.Duration `mapstructure:"metrics_flush_interval"`
}

Config defines the configuration options for the host_info connector.

func (Config) Validate

func (c Config) Validate() error

Validate checks if the configuration is valid

Jump to

Keyboard shortcuts

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