logs

package
v0.63.0 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package logs provides utils for transforming OTLP LogRecord to Datadog format it also provides sender for submitting transformed logs to datadog backend This uses datadog-api-client-go for submitting logs

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Transform

Transform converts the log record in lr, which came in with the resource in res to a Datadog log item. the variable specifies if the log body should be sent as an attribute or as a plain message.

Types

type Sender

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

Sender submits logs to Datadog intake

func NewSender

func NewSender(endpoint string, logger *zap.Logger, s exporterhelper.TimeoutSettings, insecureSkipVerify bool, apiKey string) *Sender

NewSender creates a new Sender

func (*Sender) SubmitLogs

func (s *Sender) SubmitLogs(ctx context.Context, payload []datadogV2.HTTPLogItem) error

SubmitLogs submits the logs contained in payload to the Datadog intake

Jump to

Keyboard shortcuts

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