<div dir="ltr"><div dir="ltr"><br></div><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Am Mi., 27. Mai 2020 um 10:52 Uhr schrieb Vance Shipley <<a href="mailto:vances@motivity.ca">vances@motivity.ca</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Is there a built in method to port this simple behaviour to the new logger?<div><br></div><div>1> error_logger:info_report(["Something happened", {state, active}]).<br>ok<br>=INFO REPORT==== 27-May-2020::16:47:11.797398 ===<br> "Something happened"<br> state: active</div></div></blockquote><div><br></div><div>The format of a report in logger differs from error_logger. Maybe something like this:</div><div><br></div><div>$ erl<br>Erlang/OTP 23 [erts-11.0] [source] [64-bit] [smp:12:12] [ds:12:12:10] [async-threads:1]<br><br>Eshell V11.0 (abort with ^G)<br>1> logger:set_primary_config(#{level => info}).<br>ok<br>2> logger:info([{msg, "Something happened"}, {state, active}]).<br>=INFO REPORT==== 27-May-2020::12:08:54.987946 ===<br> msg: Something happened<br> state: active<br>ok<br>3> logger:info(#{msg => "Something happened", state => active}). <br>=INFO REPORT==== 27-May-2020::12:09:10.560152 ===<br> msg: Something happened<br> state: active<br>ok<br>4></div><div><br></div><div>Andreas<br></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><br></div>-- <br><div dir="ltr"> -Vance</div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><p><span style="font-family:verdana,geneva,sans-serif;font-size:10pt">Andreas Schultz<br></span></p>
</div></div>