batchemitter

package
v4.2.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BatchEmitter

type BatchEmitter struct {
	*baseemitter.BaseEmitter

	Metrics []telegraf.Metric
	// contains filtered or unexported fields
}

BatchEmitter gathers a batch of telegraf measurements that can be modified and then emitted

func NewEmitter

func NewEmitter(Output types.Output, Logger log.FieldLogger) *BatchEmitter

NewEmitter returns a new BatchEmitter that gathers a batch of telegraf measurements so they can be modified and then emitted

func (*BatchEmitter) AddMetric

func (b *BatchEmitter) AddMetric(m telegraf.Metric)

AddMetric takes a telegraf metric and saves it to the struct member Metrics

func (*BatchEmitter) Send

func (b *BatchEmitter) Send()

Send the metrics in the batch through the agent

Jump to

Keyboard shortcuts

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