loggerutils

package
v1.12.3-rc1 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2016 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseLogTag

func ParseLogTag(ctx logger.Context, defaultTemplate string) (string, error)

ParseLogTag generates a context aware tag for consistency across different log drivers based on the context of the running container.

Types

type RotateFileWriter added in v1.10.0

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

RotateFileWriter is Logger implementation for default Docker logging.

func NewRotateFileWriter added in v1.10.0

func NewRotateFileWriter(logPath string, capacity int64, maxFiles int) (*RotateFileWriter, error)

NewRotateFileWriter creates new RotateFileWriter

func (*RotateFileWriter) Close added in v1.10.0

func (w *RotateFileWriter) Close() error

Close closes underlying file and signals all readers to stop.

func (*RotateFileWriter) LogPath added in v1.10.0

func (w *RotateFileWriter) LogPath() string

LogPath returns the location the given writer logs to.

func (*RotateFileWriter) MaxFiles added in v1.10.0

func (w *RotateFileWriter) MaxFiles() int

MaxFiles return maximum number of files

func (*RotateFileWriter) NotifyRotate added in v1.10.0

func (w *RotateFileWriter) NotifyRotate() chan interface{}

NotifyRotate returns the new subscriber

func (*RotateFileWriter) NotifyRotateEvict added in v1.10.0

func (w *RotateFileWriter) NotifyRotateEvict(sub chan interface{})

NotifyRotateEvict removes the specified subscriber from receiving any more messages.

func (*RotateFileWriter) Write added in v1.10.0

func (w *RotateFileWriter) Write(message []byte) (int, error)

WriteLog write log message to File

Jump to

Keyboard shortcuts

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