stdout

package
v0.0.0-...-65a99ba Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: MIT Imports: 11 Imported by: 2

Documentation

Index

Constants

View Source
const BackendName = "stdout"

BackendName is the name of this backend.

Variables

This section is empty.

Functions

func NewClientFromViper

func NewClientFromViper(v *viper.Viper, logger logrus.FieldLogger, pool *transport.TransportPool) (gostatsd.Backend, error)

NewClientFromViper constructs a stdout backend.

Types

type Client

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

Client is an object that is used to send messages to stdout.

func NewClient

func NewClient(disabled gostatsd.TimerSubtypes) (*Client, error)

NewClient constructs a stdout backend.

func (Client) Name

func (Client) Name() string

Name returns the name of the backend.

func (Client) SendEvent

func (client Client) SendEvent(ctx context.Context, e *gostatsd.Event) (retErr error)

SendEvent prints events to the stdout.

func (Client) SendMetricsAsync

func (client Client) SendMetricsAsync(ctx context.Context, metrics *gostatsd.MetricMap, cb gostatsd.SendCallback)

SendMetricsAsync prints the metrics in a MetricsMap to the stdout, preparing payload synchronously but doing the send asynchronously.

Jump to

Keyboard shortcuts

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