loghooks

package
v1.5.2 Latest Latest
Warning

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

Go to latest
Published: Jul 26, 2021 License: MIT Imports: 4 Imported by: 1

Documentation

Overview

UDPHook sends logs via brain-dead syslog loggers a la Sumo Logic's collector. Does not respect Syslog protocol at all. It simply fires loglines at a remote UDP address. If you want real Syslog, use the built-in Logrus SyslogHook.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UDPHook

type UDPHook struct {
	Conn       net.Conn
	RemoteAddr string
}

func NewUDPHook

func NewUDPHook(raddr string) (*UDPHook, error)

func (*UDPHook) Fire

func (hook *UDPHook) Fire(entry *logrus.Entry) error

func (*UDPHook) Levels

func (hook *UDPHook) Levels() []logrus.Level

Jump to

Keyboard shortcuts

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