Documentation ¶
Index ¶
- Constants
- func Debug(ctx context.Context, msg, category string)
- func Error(ctx context.Context, msg, category string)
- func Fatal(ctx context.Context, msg, category string)
- func Info(ctx context.Context, msg, category string)
- func Logger() *zap.Logger
- func Setup(opts ...Option)
- func Warn(ctx context.Context, msg, category string)
- type Config
- type Option
- type Options
Constants ¶
View Source
const ( LevelDebug = "debug" LevelInfo = "info" LevelWarn = "warn" LevelError = "error" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Option ¶
type Option func(*Options)
func FileCompress ¶
func FileMaxAge ¶
func FileMaxBackups ¶
func FileMaxSize ¶
type Options ¶
type Options struct { LogPath string `json:"log_path" mapstructure:"log_path"` FileMaxSize int `json:"file_max_size" mapstructure:"file_max_size" ` FileMaxBackups int `json:"file_max_backups" mapstructure:"file_max_backups"` FileMaxAge int `json:"file_max_age" mapstructure:"file_max_age"` FileCompress bool `json:"file_compress" mapstructure:"file_compress"` LogLevel string `json:"log_level" mapstructure:"log_level"` }
Click to show internal directories.
Click to hide internal directories.