From d9e58a29f9194ea8b2d9e1bdcf5b89a9cc29f988 Mon Sep 17 00:00:00 2001 From: Siri Hansen Date: Tue, 4 Sep 2018 14:30:49 +0200 Subject: [logger] Update doc about file options in logger_std_h --- lib/kernel/doc/src/logger_std_h.xml | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) (limited to 'lib/kernel') diff --git a/lib/kernel/doc/src/logger_std_h.xml b/lib/kernel/doc/src/logger_std_h.xml index b526ed037d..fcd8189bae 100644 --- a/lib/kernel/doc/src/logger_std_h.xml +++ b/lib/kernel/doc/src/logger_std_h.xml @@ -59,13 +59,22 @@

This has the value standard_io, standard_error, {file,LogFileName}, or {file,LogFileName,LogFileOpts}.

+

If LogFileOpts is specified, it replaces the default + list of options used when opening the log file. The default + list is [raw,append,delayed_write]. One reason to do + so can be to change append to, for + example, write, ensuring that the old log is + truncated when a node is restarted. See the reference manual + for file:open/2 + for more information about file options.

+

Log files are always UTF-8 encoded. The encoding can not be + changed by setting the option {encoding,Encoding} + in LogFileOpts.

+

Notice that the standard handler does not have support for + circular logging. Use the disk_log handler, + logger_disk_log_h, + for this.

Defaults to standard_io.

-

It is recommended not to specify LogFileOpts unless absolutely - necessary. The default options used by the handler to open a file for logging are - raw, append, and delayed_write. Notice that the standard - handler does not have support for circular logging. Use the disk_log handler, - logger_disk_log_h, - for this.

filesync_repeat_interval @@ -73,12 +82,12 @@ a file sync operation to write buffered data to disk. The handler attempts the operation repeatedly, but only performs a new sync if something has actually been logged.

-

Defaults to 5000 milliseconds.

If no_repeat is set as value, the repeated file sync operation is disabled, and it is the operating system settings that determine how quickly or slowly data is written to disk. The user can also call the filesync/1 function to perform a file sync.

+

Defaults to 5000 milliseconds.

Other configuration parameters exist, to be used for customizing -- cgit v1.2.3