[erlang-questions] Simple Logging

Jesper Louis Andersen <>
Mon Feb 3 22:58:32 CET 2014

On Mon, Feb 3, 2014 at 10:29 PM, Niklas Semmler <> wrote:

> The code I am working on is supposed to be integrated with a bigger system
> later on. As far as I know the other system uses native logging.

I'd use the error_logger framework then. First of all, it is generic and
lager as well as the native logger plugs into that framework with a
gen_event. Just call error_logger:error_report/1 and friends. It will
decouple logging from the rest of the system. For low-level debugging, look
into skipping log statements. Go for using 'dbg' instead, since it is often
more effective.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20140203/a34d5477/attachment.html>

More information about the erlang-questions mailing list