logger

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2024 License: BSD-2-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	Parent interfaces.ILogger
	Config FileConfig
	// contains filtered or unexported fields
}

func NewFile added in v0.0.9

func NewFile(cfg FileConfig, parent interfaces.ILogger) *File

func (*File) Debug

func (t *File) Debug(ctx context.Context, args ...interface{})

func (*File) Error

func (t *File) Error(ctx context.Context, err error)

func (*File) Fatal

func (t *File) Fatal(ctx context.Context, err error)

func (*File) Info

func (t *File) Info(ctx context.Context, args ...interface{})

func (*File) Init

func (t *File) Init(cfg interfaces.IConfig) error

func (*File) Message

func (t *File) Message(ctx context.Context, args ...interface{})

func (*File) Panic

func (t *File) Panic(ctx context.Context, err error)

func (*File) SetLevel

func (t *File) SetLevel(level interfaces.LogLevel)

func (*File) Stop

func (t *File) Stop() error

func (*File) Warn

func (t *File) Warn(ctx context.Context, args ...interface{})

type FileConfig added in v0.0.9

type FileConfig struct {
	Level interfaces.LogLevel `yaml:"level"`
	FName string              `yaml:"filename"`
}

type Mock

type Mock struct {
}

func NewMock added in v0.0.9

func NewMock() *Mock

func (*Mock) Debug

func (t *Mock) Debug(ctx context.Context, args ...interface{})

func (*Mock) Error

func (t *Mock) Error(ctx context.Context, err error)

func (*Mock) Fatal

func (t *Mock) Fatal(ctx context.Context, err error)

func (*Mock) Info

func (t *Mock) Info(ctx context.Context, args ...interface{})

func (*Mock) Init

func (t *Mock) Init(cfg interfaces.IConfig) error

func (*Mock) Message

func (t *Mock) Message(ctx context.Context, args ...interface{})

func (*Mock) Panic

func (t *Mock) Panic(ctx context.Context, err error)

func (*Mock) SetLevel

func (t *Mock) SetLevel(level interfaces.LogLevel)

func (*Mock) Stop

func (t *Mock) Stop() error

func (*Mock) Warn

func (t *Mock) Warn(ctx context.Context, args ...interface{})

type Sentry added in v0.2.0

type Sentry struct {
	Parent interfaces.ILogger
	Config SentryConfig
	// contains filtered or unexported fields
}

func NewSentry added in v0.2.0

func NewSentry(cfg SentryConfig, parent interfaces.ILogger) *Sentry

func (*Sentry) Debug added in v0.2.0

func (t *Sentry) Debug(ctx context.Context, args ...interface{})

func (*Sentry) Error added in v0.2.0

func (t *Sentry) Error(ctx context.Context, err error)

func (*Sentry) Fatal added in v0.2.0

func (t *Sentry) Fatal(ctx context.Context, err error)

func (*Sentry) Info added in v0.2.0

func (t *Sentry) Info(ctx context.Context, args ...interface{})

func (*Sentry) Init added in v0.2.0

func (t *Sentry) Init(cfg interfaces.IConfig) error

func (*Sentry) Message added in v0.2.0

func (t *Sentry) Message(ctx context.Context, args ...interface{})

func (*Sentry) Panic added in v0.2.0

func (t *Sentry) Panic(ctx context.Context, err error)

func (*Sentry) SetLevel added in v0.2.0

func (t *Sentry) SetLevel(level interfaces.LogLevel)

func (*Sentry) Stop added in v0.2.0

func (t *Sentry) Stop() error

func (*Sentry) Warn added in v0.2.0

func (t *Sentry) Warn(ctx context.Context, args ...interface{})

type SentryConfig added in v0.2.0

type SentryConfig struct {
	Level           interfaces.LogLevel `yaml:"level"`
	SentryURL       string              `yaml:"sentry_url"`
	AppEnv          string              `yaml:"app_env"`
	SampleRate      float64             `yaml:"sample_rate"`
	TraceSampleRate float64             `yaml:"trace_sample_rate"`
}

type Std

type Std struct {
	Parent interfaces.ILogger
	Config StdConfig
	// contains filtered or unexported fields
}

func NewStd added in v0.0.9

func NewStd(cfg StdConfig, parent interfaces.ILogger) *Std

func (*Std) Debug

func (t *Std) Debug(ctx context.Context, args ...interface{})

func (*Std) Error

func (t *Std) Error(ctx context.Context, err error)

func (*Std) Fatal

func (t *Std) Fatal(ctx context.Context, err error)

func (*Std) Info

func (t *Std) Info(ctx context.Context, args ...interface{})

func (*Std) Init

func (t *Std) Init(cfg interfaces.IConfig) error

func (*Std) Message

func (t *Std) Message(ctx context.Context, args ...interface{})

func (*Std) Panic

func (t *Std) Panic(ctx context.Context, err error)

func (*Std) SetLevel

func (t *Std) SetLevel(level interfaces.LogLevel)

func (*Std) Stop

func (t *Std) Stop() error

func (*Std) Warn

func (t *Std) Warn(ctx context.Context, args ...interface{})

type StdConfig added in v0.0.9

type StdConfig struct {
	Level interfaces.LogLevel `yaml:"level"`
}

Jump to

Keyboard shortcuts

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