remotewrite

package
v0.26.1 Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2022 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BasicAuthConfig

type BasicAuthConfig struct {
	Username string          `hcl:"username"`
	Password hcltypes.Secret `hcl:"password"`
}

BasicAuthConfig is the metrics_forwarder's configuration for authenticating against the remote system when sending metrics.

type Component

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

Component is the metrics_forwarder component.

func NewComponent

func NewComponent(o component.Options, c RemoteConfig) (*Component, error)

NewComponent creates a new metrics_forwarder component.

func (*Component) Collect

func (c *Component) Collect(ch chan<- prometheus.Metric)

Collect implements prometheus.Collector.

func (*Component) Config

func (c *Component) Config() RemoteConfig

Config implements Component.

func (*Component) Describe

func (c *Component) Describe(ch chan<- *prometheus.Desc)

Describe implements prometheus.Collector.

func (*Component) Receive

func (c *Component) Receive(ts int64, metricArr []*metrics.FlowMetric)

Receive implements the receiver.receive func that allows an array of metrics to be passed

func (*Component) Run

func (c *Component) Run(ctx context.Context) error

Run implements Component.

func (*Component) Update

func (c *Component) Update(newConfig component.Arguments) error

Update implements Component.

type Config

type Config struct {
	Name      string           `hcl:"name,optional"`
	URL       string           `hcl:"url"`
	BasicAuth *BasicAuthConfig `hcl:"basic_auth,block"`
}

Config is the metrics_fowarder's configuration for where to send metrics stored in the WAL.

type Export

type Export struct {
	Receiver *metrics.Receiver `hcl:"receiver"`
}

Export is used to assign this to receive metrics

type RemoteConfig

type RemoteConfig struct {
	ExternalLabels map[string]string `hcl:"external_labels,optional"`
	RemoteWrite    []*Config         `hcl:"remote_write,block"`
}

RemoteConfig represents the input state of the metrics_forwarder component.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳