log4cats
log4cats copied to clipboard
FiberLocal / IOLocal logger wrapper
hopefully self-explanatory: it would be great to have a wrapper for loggers that would allow one to pass structured logging context in a more implicit fashion.
This would probably involve creating a root logging context (the default value of the IOLocal), then using that in a wrapped logger so it passes the context to the underlying logger (e.g. slf4j).
Would something like this be helpful? https://github.com/typelevel/log4cats/pull/676
Yes, that's pretty much what I was looking for :)
Maybe some utility that would create the IOLocal for you would also be nice.