cloudwatch

package
v2.0.0-...-675b67f Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudwatchInput

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

CloudwatchInput is an operator that reads input from AWS Cloudwatch Logs.

func (*CloudwatchInput) Start

func (c *CloudwatchInput) Start(persister operator.Persister) error

Start will start generating log entries.

func (*CloudwatchInput) Stop

func (c *CloudwatchInput) Stop() error

Stop will stop generating logs.

type CloudwatchInputConfig

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

	// LogGroupName is deprecated but still supported for compatibility with older configurations
	LogGroupName string `json:"log_group_name,omitempty" yaml:"log_group_name,omitempty"`

	// LogGroups is a list of log groups
	LogGroups []string `json:"log_groups,omitempty" yaml:"log_groups,omitempty"`

	// LogGroupPrefix is used to append to LogGroups and can be used in conjunction with LogGroups
	LogGroupPrefix string `json:"log_group_prefix,omitempty" yaml:"log_group_prefix,omitempty"`

	// Region is the AWS region to target
	Region string `json:"region,omitempty" yaml:"region,omitempty"`

	// optional
	LogStreamNamePrefix string          `json:"log_stream_name_prefix,omitempty" yaml:"log_stream_name_prefix,omitempty"`
	LogStreamNames      []*string       `json:"log_stream_names,omitempty" yaml:"log_stream_names,omitempty"`
	Profile             string          `json:"profile,omitempty" yaml:"profile,omitempty"`
	EventLimit          int64           `json:"event_limit,omitempty" yaml:"event_limit,omitempty"`
	PollInterval        helper.Duration `json:"poll_interval,omitempty" yaml:"poll_interval,omitempty"`
	StartAt             string          `json:"start_at,omitempty" yaml:"start_at,omitempty"`
}

CloudwatchInputConfig is the configuration of a AWS Cloudwatch Logs input operator.

func NewCloudwatchConfig

func NewCloudwatchConfig(operatorID string) *CloudwatchInputConfig

NewCloudwatchConfig creates a new AWS Cloudwatch Logs input config with default values

func (*CloudwatchInputConfig) Build

func (c *CloudwatchInputConfig) Build(buildContext operator.BuildContext) ([]operator.Operator, error)

Build will build a AWS Cloudwatch Logs input operator.

type Persister

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

func (*Persister) Read

func (p *Persister) Read(ctx context.Context, key string) (int64, error)

Helper function to get persisted data

func (*Persister) Write

func (p *Persister) Write(ctx context.Context, key string, value int64) error

Helper function to set persisted data

Jump to

Keyboard shortcuts

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