Add structured logging capabilities
jehrhardt opened this issue · comments
Jan Ehrhardt commented
Erlang's Logger module is much more powerful than what this library exposes to Gleam applications. Regarding structured logging, I consider the following as basics for a logging library:
- Passing meta data to log events
- Setting global and process level meta data
- Making the formatter / handler configurable (e.g. pass a custom Gleam function)
- Provide an optional default JSON formatter
- Convenience functions like
debug
anderror
that automatically set the level
I would like to provide some pull requests to implement the above. But I would also like to get your opinion on which points make sense to you as well.
Louis Pilfold commented
Hello! This is not in scope for this simple library. You can use one of the other existing logging library which do support this.
Jan Ehrhardt commented
Thanks for clarification.