output

package
v0.0.0-...-88a36fa Latest Latest
Warning

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

Go to latest
Published: May 25, 2023 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ECSWriter

type ECSWriter interface {
	//WriteECSRecords writes out deserialized ECS records
	WriteECSRecords(outputData []input.ECSRecord) error
	//Close frees any resources held by this writer
	Close() error
}

ECSWriter writes out deserialized Elastic Common Schema records

type ElasticWriter

type ElasticWriter struct {
	config.ESStaticCfg
	// contains filtered or unexported fields
}

func (ElasticWriter) Close

func (e ElasticWriter) Close() error

Close does nothing for the ElasticWriter since each document is written with its own TCP session. This will likely be needed if we implement the Bulk API.

func (ElasticWriter) WriteECSRecords

func (e ElasticWriter) WriteECSRecords(outputData []string, beatsVersion string) error

WriteECSRecords sends the outputData to Elasticsearch

type JSONWriter

type JSONWriter interface {
	//WriteECSRecords writes out JSON formatted ECS records
	WriteECSRecords(outputData []string, beatsVersion string) error
	//Close frees any resources held by this writer
	Close() error
}

JSONWriter writes a log entry in raw json format to a destination

func NewElasticWriter

func NewElasticWriter(static config.ESStaticCfg, running config.ESRunningCfg) JSONWriter

NewElasticWriter returns a JSONWriter which sends JSON document to an Elasticsearch index

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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