cwlogs

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2019 License: Apache-2.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 CloudwatchLogsReader

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

CloudwatchLogsReader cloudwatch log reader which uploads chunk of log data to buildkite

func NewCloudwatchLogsReader

func NewCloudwatchLogsReader(cfgs ...*aws.Config) *CloudwatchLogsReader

NewCloudwatchLogsReader read all the things

func (*CloudwatchLogsReader) ReadLogs

func (cwlr *CloudwatchLogsReader) ReadLogs(rlr *ReadLogsParams) (*ReadLogsResult, error)

ReadLogs this reads a page of logs from cloudwatch and returns a token which will access the next page

type LogLine

type LogLine struct {
	Timestamp time.Time `json:"timestamp,omitempty"`
	Message   string    `json:"message,omitempty"`
}

LogLine logs data

type LogsReader

type LogsReader interface {
	ReadLogs(*ReadLogsParams) (*ReadLogsResult, error)
}

LogsReader logs reader

type ReadLogsParams

type ReadLogsParams struct {
	GroupName  string  `json:"group_name,omitempty" jsonschema:"required"`
	StreamName string  `json:"stream_name,omitempty" jsonschema:"required"`
	NextToken  *string `json:"next_token,omitempty"`
}

ReadLogsParams read cloudwatch logs parameters

type ReadLogsResult

type ReadLogsResult struct {
	LogLines  []*LogLine `json:"log_lines,omitempty"`
	NextToken *string    `json:"next_token,omitempty"`
}

ReadLogsResult read cloudwatch logs result

Jump to

Keyboard shortcuts

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