logger

package
v0.0.0-...-0dcd02c Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2017 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 4 more Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LOGLEVEL_ENV_VAR = "ECS_LOGLEVEL"
	LOGFILE_ENV_VAR  = "ECS_LOGFILE"

	DEFAULT_LOGLEVEL = "debug"
)

Variables

This section is empty.

Functions

func GetLevel

func GetLevel() string

GetLevel gets the log level

func SetLevel

func SetLevel(logLevel string)

SetLevel sets the log level for logging

Types

type OldLogger

type OldLogger interface {
	// New returns an OldLogger instance with the passed ctx plus existing ctx
	New(ctx ...interface{}) OldLogger

	// Log a message at the given level with context key/value pairs
	Debug(msg string, ctx ...interface{})
	Info(msg string, ctx ...interface{})
	Warn(msg string, ctx ...interface{})
	Error(msg string, ctx ...interface{})
	Crit(msg string, ctx ...interface{})
}

func ForModule

func ForModule(module string) OldLogger

ForModule returns an OldLogger instance. OldLogger is deprecated and kept for compatibility reasons. Prefer using Seelog directly.

type Shim

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

func (*Shim) Crit

func (s *Shim) Crit(msg string, ctx ...interface{})

func (*Shim) Debug

func (s *Shim) Debug(msg string, ctx ...interface{})

func (*Shim) Error

func (s *Shim) Error(msg string, ctx ...interface{})

func (*Shim) Info

func (s *Shim) Info(msg string, ctx ...interface{})

func (*Shim) New

func (s *Shim) New(ctx ...interface{}) OldLogger

func (*Shim) Warn

func (s *Shim) Warn(msg string, ctx ...interface{})

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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