syslog

package
v0.0.0-...-aba53e5 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2023 License: MIT Imports: 9 Imported by: 0

README

Syslog - internal notes

go get github.com/influxdata/go-syslog/v3

https://github.com/influxdata/go-syslog

Documentation

Index

Constants

View Source
const AppNameField = "appname" // default appname
View Source
const ErrorTag = "gogstash_filter_syslog_error"

ErrorTag tag added to event when process module failed

View Source
const HostnameField = "hostname" // default hostname
View Source
const MessageField = "syslog_message" // default field for syslog message
View Source
const MessageIdField = "message_id" // default message id
View Source
const ModuleName = "syslog"

ModuleName is the name used in config file

View Source
const PriorityField = "priority" // default priority
View Source
const SeverityField = "severity" // default severity

Variables

This section is empty.

Functions

func InitHandler

func InitHandler(ctx context.Context, raw config.ConfigRaw, control config.Control) (config.TypeFilterConfig, error)

InitHandler initialize the filter plugin

Types

type FilterConfig

type FilterConfig struct {
	config.FilterConfig

	Source         string `json:"source" yaml:"source"`                 // source message field name
	Format         string `json:"format" yaml:"format"`                 // input format, either RFC3164 or RFC5424
	SaveTime       bool   `json:"save_time" yaml:"save_time"`           // if true time from syslog is kept
	RemoveSource   bool   `json:"remove_source" yaml:"remove_source"`   // if true source message is removed (upon success)
	MessageField   string `json:"message_field" yaml:"message_field"`   // syslog message
	HostnameField  string `json:"hostname_field" yaml:"hostname_field"` // hostname
	AppNameField   string `yaml:"app_name_field" json:"app_name_field"` // appname
	SeverityField  string `json:"severity_field" yaml:"severity_field"`
	PriorityField  string `json:"priority_field" yaml:"priority_field"`
	MessageIdField string `json:"message_id_field" yaml:"message_id_field"`
	// contains filtered or unexported fields
}

FilterConfig holds the configuration json fields and internal objects

func DefaultFilterConfig

func DefaultFilterConfig() FilterConfig

DefaultFilterConfig returns an FilterConfig struct with default values

func (*FilterConfig) Event

Event the main filter event

Jump to

Keyboard shortcuts

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