writer

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2020 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Overview

Package writer provides an io.Writer interface to CloudWatch Logs

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

Client is a CloudWatch Logs client

type LogWriter

type LogWriter struct {
	sync.Mutex
	// contains filtered or unexported fields
}

LogWriter provides an io.Writer interface to CloudWatch Logs

The zero-value is not usable. New should be used to construct a new LogWriter

func New

func New(logGroup, logStream string, client Client) *LogWriter

New constructs and returns a new LogWriter

func (*LogWriter) Close

func (w *LogWriter) Close() error

Close implements io.Closer. This method will stop the writer and flush any buffered log events

func (*LogWriter) Flush

func (w *LogWriter) Flush() error

Flush writes any buffered log events to CloudWatch Logs

func (*LogWriter) Write

func (w *LogWriter) Write(data []byte) (int, error)

Write implements io.Writer

Jump to

Keyboard shortcuts

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