Age | Commit message (Collapse) | Author |
|
The new parameter to this function, SetOrUpdate, indicates how
unspecified configuration data fields shall be set. The rule is that
if SetOrUpdate equals set, then default values shall be used, and if
SetOrUpdate equals update, then existing configuration values shall be
used. Consequently, these examples now apply to logger_std_h and
logger_disk_log_h:
set_handler_config(default, config, #{sync_mode_qlen => 20}) sets the
value of sync_mode_qlen to 20, and resets all other (writable) fields
in the config map to their default values.
update_handler_config(default, config, #{sync_mode_qlen => 20}) sets
the value of sync_mode_qlen to 20, and leaves all other fields in the
config map unchanged.
|
|
This function is similar to set_handler_config/3, but calls the handler
callback changing_config/3 with the first parameter SetOrUpdate=update.
|
|
Since logger has now knowledge of the handler specific data ('config'
field in the handler configuration map), it can not merge this data
structure with default or old values upon configuration
change. Instead, the handler callback changing_config must do
this. Earlier, this callback did not reflect if the configuration
change was initiated by a call to set_handler_config or
update_handler_config, so the handler did not know if unspecified
fields should get default values or the values from the existing
configuration.
To overcome this problem, the new parameter SetOrUpdate is added to
this callback. If SetOrUpdate equals set, then default values should
be used. If SetOrUpdate equals update, then existing configuration
values should be used.
|
|
If a filter fails, it is removed by a call to
logger:remove_filter/1,2. If the log event that caused the failure was
issued on the logger process itself, this would earlier cause a
deadlock due to a gen_server:call to self(). This is now prevented.
|
|
|
|
|
|
OTP-15146
|
|
|
|
|
|
Log events issued via error_logger:info_msg or
error_logger:info_report are now forwarded to Logger with level
'notice' instead of 'info'.
Log events issued by gen_* behaviours are also changed from level
'info' to level 'notice'.
Progress reports are still 'info', and can therefore easily be
included/excluded by changing the primary log level. By default, they
are not logged.
|
|
* lukas/kernel/logger-config/OTP-13295:
erts: Fix emulator log messages to use erlang:system_time
kernel: Add LOGGER_SERVER_TAG to logger_server
|
|
Module and Id are now always included as fields in Config, so these
are no longer returned as separate elements.
|
|
And add field 'module' in handler config.
|
|
Function names changed:
get/set/update_logger_config -> get/set/update_primary_config
add/remove_logger_filter -> add/remove_primary_filter
|
|
New default for handlers is 'all'.
|
|
* Level can now be set/unset for multiple modules in one call.
* Added functions get_module_level/0 and get_module_level/1.
|
|
|
|
This makes recursive calls to not dead-lock logger_server.
|
|
Also, change HandlerId from logger_simple to simple.
|
|
|
|
|
|
|
|
|
|
|
|
This field contains the index of all installed handlers. It is
internal and can not be altered by the user, and should therefore not
be visible.
|
|
|
|
|
|
Most logger configuration that was possible through
kernel application variables have been moved into a
common 'logger' application environment in kernel.
Now all the configuration possible through the logger
API can be done as sys config.
The handler started by kernel has been renamed to 'default'
instead of logger_std_h.
There is a new logger:setup_handlers/1 function that given an
application name can be used to setup handlers in other applications.
|
|
|
|
|
|
|