newrelic_logrus

package
v0.0.0-...-e3411e0 Latest Latest
Warning

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

Go to latest
Published: May 18, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Formatter

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

A Formatter implements the logrus.Formatter interface and allows filtering out certain fields.

func NewFormatter

func NewFormatter(fieldList []string, formatter logrus.Formatter) *Formatter

NewFormatter creates a properly configure formatter

func (*Formatter) Format

func (f *Formatter) Format(entry *logrus.Entry) ([]byte, error)

Format takes a Logrus entry and then formats it into the correct output. It does that by manipulating the fields and then calling the underlying formatter it was constructed with.

type NewRelicLogrusHook

type NewRelicLogrusHook struct {
	Application *newrelic.Application
	LogLevels   []logrus.Level
	// contains filtered or unexported fields
}

func NewNewRelicLogrusHook

func NewNewRelicLogrusHook(app *newrelic.Application, levels []logrus.Level) *NewRelicLogrusHook

func (*NewRelicLogrusHook) Fire

func (n *NewRelicLogrusHook) Fire(entry *logrus.Entry) error

func (*NewRelicLogrusHook) Levels

func (n *NewRelicLogrusHook) Levels() []logrus.Level

Jump to

Keyboard shortcuts

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