lpil / logging

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add structured logging capabilities

jehrhardt opened this issue · comments

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 and error 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.

Hello! This is not in scope for this simple library. You can use one of the other existing logging library which do support this.

Thanks for clarification.