Releases: gol4ng/logger
v0.5.1
Add some Field/Fields method
v0.5.0
Improve logger signature error handling (#64)
⚠️ Breaking change
-
Signature change
-
No more context mandatory
-
No more return error (LogInterface, LoggerInterface) use errorHandler instead
-
Field now contain his name as attribute
-
We replace
-
formatter.EnableColor by formatter.WithColor
-
formatter.DisplayContext by formatter.WithContext
v0.4.2
v0.4.1
v0.4.0
⚠️ Testing BC Break
the testing.Logger{}
become a real Logger
with a special in memory handler in order to do some assertion during tests
Migration
myLogger := &testing_logger.Logger{}
// some code that log
entries := myLogger.GetEntries()
assert.Len(t, entries, 5) // your logging assertions
BECOME
myLogger, store := testing_logger.NewLogger()
// some code that log
entries := store.GetEntries()
assert.Len(t, entries, 5) // your logging assertions
v0.3.4
change
Wrap(middleware MiddlewareInterface) LoggerInterface
to
Wrap(middlewares ...MiddlewareInterface) LoggerInterface
AND
WrapNew(middleware MiddlewareInterface) LoggerInterface
to
WrapNew(middlewares ...MiddlewareInterface) LoggerInterface
v0.3.3
fix testing logger entries race condition
v0.3.2
[Testing] add a testing logger for third parties test usage
[Testing] add Loggerinterface WrappableLoggerInterface LogInterface
v0.3.1
Add missing mocks for third party testing