Releases: edoger/zkits-logger
Releases Β· edoger/zkits-logger
Version 1.5.1
This is an enhanced version.
- Add utility functions to determine high and low priority levels. (
IsHighPriorityLevel(Level)
andIsLowPriorityLevel(Level)
) - Allows fetching entity buffer. (
Entity.Buffer() *bytes.Buffer
) - Add log FormatOutput support (Allows to customize the format and outputter of each log). See README.md
Version 1.5.0
- Upgrade go version to go1.18.
- Allows for custom call stack prefix filter.
- Add unimplemented log formatter.
- Add
Entity.HasFields
,Entity.HasContext
,Entity.HasCaller
,Entity.HasStack
utility methods. - Allows enabling or disabling the log hook.
- Refactor log file writer. (change backup log file name)
Version 1.4.9
Note: If there are no special circumstances, this will be the last version of v1.4.x, starting from v1.5.x, we bumped the minimum go version to go1.18.
- Add
GetHighPriorityLevels
andGetLowPriorityLevels
util function. - Add
Log.IsLevelEnabled(Level)
andLog.Is<LevelName>LevelEnabled()
to detect whether the log level is enabled. - Add
Logger.SetLevelString
andLogger.ForceSetLevelString
to support setting log level from string. - Add
Log.WithFieldPairs(key, value, key, value, ...)
method to attach tabulated key-value pair fields to log. - Some internal performance improvements and stability upgrades.
- Migrate CI to Github Actions (See #13).
Version 1.4.8
- Add NewMutexWriterWithLocker for creates mutex writer from the given sync.Locker.
- Fix caller skip issue.
- Update big log size to 4KB from 1KB.
Version 1.4.7
- Allows custom json serialization object pool.
- Renamed backup log names are accurate to nanoseconds.
- Some internal stability improvements.
Version 1.4.6
- Supports console color formatting for log levels.
- Supports adding fixed message prefix to logs.
- Support for wrapping Logger or Log as io.Writer.
- Add Logger.AsStandardLogger: Support for converting Logger to standard library *log.Logger instance.
- Allows changing the logger level at runtime.
- Fix duplicate message formatting. (in method Log.Log and method Logger.Log)
Version 1.4.5
- Add mutex writer wrapper for logger.
- Add log call stack support.
- Hide the name when the logger name is empty.
- Some internal details and performance optimizations.
Version 1.4.4
- Add Logger.AsLog method: convert the current Logger instance to a Log instance.
- Support automatic cleaning of old log files. [BREAK]
- Provides a multi-channel writer.
- Add built-in console log formatter.
Version 1.4.3
- Support log summary cloning.
- Add Logger.SetLevelsOutput() method and Logger.EnableLevelsCaller() method.
- Optimize some internal details.
Version 1.4.2
- Add default quote text formatter.
- Use short capital level text for the default provided text formatter.
- Add log file writer.
- Optimize the performance of json log.