std.experimental.logger: practical observations

Jeremy Powers via Digitalmars-d digitalmars-d at puremagic.com
Mon Sep 15 11:13:14 PDT 2014


On Sun, Sep 14, 2014 at 10:30 AM, Cliff via Digitalmars-d <
digitalmars-d at puremagic.com> wrote:

> Loggers are not *necessarily* also debuggers.  When used for post-mortem
> analysis (the typical case), it is not generally important that log data
> has been written by the time any given log method has returned - if the
> caller *intends* that, the logging system can have a sync/flush method
> similar to I/O behavior, or a configuration option to force fully
> synchronized behavior.
>
...
> - Cliff
>

+1

Logging conceptually has two parts: firing off the log message, and later
recording it.  These should be distinct, for many reasons (may want
multiple sinks for each log message, different formatting per sink, sink
handled by a different process, etc).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20140915/a95c679d/attachment.html>


More information about the Digitalmars-d mailing list