tcp

package
v1.6.2 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2022 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// DefaultMaxBufferSize is the max buffer sized used
	// if MaxBufferSize is not set
	DefaultMaxBufferSize = 1024 * 1024
)

Variables

This section is empty.

Functions

This section is empty.

Types

type TCPInput

type TCPInput struct {
	helper.InputOperator
	// contains filtered or unexported fields
}

TCPInput is an operator that listens for log entries over tcp.

func (*TCPInput) Start

func (t *TCPInput) Start() error

Start will start listening for log entries over tcp.

func (*TCPInput) Stop

func (t *TCPInput) Stop() error

Stop will stop listening for log entries over TCP.

type TCPInputConfig

type TCPInputConfig struct {
	helper.InputConfig `yaml:",inline"`

	MaxBufferSize helper.ByteSize `json:"max_buffer_size,omitempty" yaml:"max_buffer_size,omitempty"`
	ListenAddress string          `json:"listen_address,omitempty" yaml:"listen_address,omitempty"`
	TLS           TLSConfig       `json:"tls,omitempty" yaml:"tls,omitempty"`
	AddLabels     bool            `json:"add_labels,omitempty" yaml:"add_labels,omitempty"`
}

TCPInputConfig is the configuration of a tcp input operator.

func NewTCPInputConfig

func NewTCPInputConfig(operatorID string) *TCPInputConfig

NewTCPInputConfig creates a new TCP input config with default values

func (TCPInputConfig) Build

Build will build a tcp input operator.

type TLSConfig added in v0.13.14

type TLSConfig struct {
	// Enable forces the user of TLS
	Enable bool `json:"enable,omitempty" yaml:"enable,omitempty"`

	// Certificate is the file path for the certificate
	Certificate string `json:"certificate,omitempty" yaml:"certificate,omitempty"`

	// PrivateKey is the file path for the private key
	PrivateKey string `json:"private_key,omitempty" yaml:"private_key,omitempty"`

	// MinVersion is the minimum tls version
	MinVersion float32 `json:"min_version,omitempty" yaml:"min_version,omitempty"`
}

TLSConfig is the configuration for a TLS listener

Jump to

Keyboard shortcuts

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