A custom formatter for Erlang OTP logger that outputs JSON using jsx
This project should be added as a dependency to your project
sys.config
:
[ { kernel
, {logger_level, info}
, [ { logger
,[ { handler
, default
, logger_std_h
, #{formatter => {jsonformat, #{}}}
}
] }
] }
].
shell
:
> logger:info(#{a => b}).
{"a":"b","gl":"<0.178.0>","level":"info","pid":"<0.182.0>","report_cb":"fun logger:format_otp_report/1","time":1585902924341139}ok
$ rebar3 eunit
We use SemVer for versioning. For the versions available, see the tags on this repository.
We use Conventional Commits.
Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.
This project is licensed under the MIT License - see the LICENSE file for details