package easy_logging_yojson
Module Easy_logging_yojson.LoggingSource
include module type of struct include Easy_logging.Logging end
Possible level of a log item.
Source
type log_item = Easy_logging.Logging.log_item = {level : level;logger_name : string;msg : string;timestamp : float;
}Returns a registered logger by name, creating it if does not exist.
Source
val make_logger :
?propagate:bool ->
string ->
level ->
Easy_logging.Handlers.desc list ->
loggerConvenience method used to fetch a logger and initialize it.
make_logger name level handlers_descs calls get_logger with the given name, then sets its level, adds the handlers, and then returns it.
Calling this function multiple times with the same name will keep adding handlers.
Source
val tree_to_yojson :
unit ->
[> `Assoc of (string * [> `List of 'a list | `String of string ]) list ] as 'aReturns the logging tree as yojson, with logger name and level as node data.
Source
type config_logger = {name : string;level : level;handlers : Easy_logging.Handlers.desc list;propagate : bool;
}Source
val config_logger_of_yojson :
Yojson.Safe.t ->
config_logger Ppx_deriving_yojson_runtime.error_orSource
type global_config = {handlers_config : Easy_logging.Handlers.config;loggers_config : config_logger list;
}Source
val global_config_of_yojson :
Yojson.Safe.t ->
global_config Ppx_deriving_yojson_runtime.error_or