dm_logger Module

Object-oriented logger that outputs logs and optionally forwards them via POSIX message queue.

Only a single receiver is allowed (but multiple senders). Otherwise, the log messages are passed in round-robin fashion to the receivers.

Get a pointer to the logger before configuration and invocation:

class(logger_class), pointer :: logger

logger => dm_logger_get_default()
call logger%configure(name='dmlogger', ipc=.true., verbose=.true.)
call logger%error('log message')

The log message is sent do the dmlogger(1) instance of name dmlogger, i.e., to POSIX message queue /dmlogger.


Uses

  • module~~dm_logger~~UsesGraph module~dm_logger dm_logger module~dm_ansi dm_ansi module~dm_logger->module~dm_ansi module~dm_error dm_error module~dm_logger->module~dm_error module~dm_id dm_id module~dm_logger->module~dm_id module~dm_kind dm_kind module~dm_logger->module~dm_kind module~dm_log dm_log module~dm_logger->module~dm_log module~dm_node dm_node module~dm_logger->module~dm_node module~dm_observ dm_observ module~dm_logger->module~dm_observ module~dm_type dm_type module~dm_logger->module~dm_type module~dm_ascii dm_ascii module~dm_ansi->module~dm_ascii module~dm_error->module~dm_kind module~dm_error->module~dm_ascii iso_fortran_env iso_fortran_env module~dm_kind->iso_fortran_env module~dm_log->module~dm_error module~dm_log->module~dm_id module~dm_log->module~dm_kind module~dm_log->module~dm_node module~dm_log->module~dm_observ module~dm_sensor dm_sensor module~dm_log->module~dm_sensor module~dm_target dm_target module~dm_log->module~dm_target module~dm_time dm_time module~dm_log->module~dm_time module~dm_uuid dm_uuid module~dm_log->module~dm_uuid module~dm_node->module~dm_id module~dm_node->module~dm_kind module~dm_observ->module~dm_error module~dm_observ->module~dm_id module~dm_observ->module~dm_kind module~dm_observ->module~dm_node module~dm_request dm_request module~dm_observ->module~dm_request module~dm_response dm_response module~dm_observ->module~dm_response module~dm_observ->module~dm_sensor module~dm_observ->module~dm_target module~dm_observ->module~dm_time module~dm_util dm_util module~dm_observ->module~dm_util module~dm_observ->module~dm_uuid module~dm_request->module~dm_error module~dm_request->module~dm_id module~dm_request->module~dm_kind module~dm_request->module~dm_response module~dm_request->module~dm_time module~dm_request->module~dm_util module~dm_string dm_string module~dm_request->module~dm_string module~dm_response->module~dm_error module~dm_response->module~dm_id module~dm_response->module~dm_kind module~dm_response->module~dm_util module~dm_sensor->module~dm_id module~dm_sensor->module~dm_kind module~dm_sensor->module~dm_node module~dm_target->module~dm_id module~dm_target->module~dm_kind module~dm_target->module~dm_util module~dm_time->module~dm_error module~dm_time->module~dm_kind module~dm_time->module~dm_util module~dm_util->module~dm_error module~dm_util->module~dm_kind module~dm_string->module~dm_error module~dm_string->module~dm_kind

Used by

  • module~~dm_logger~~UsedByGraph module~dm_logger dm_logger module~dmpack dmpack module~dmpack->module~dm_logger

Variables

Type Visibility Attributes Name Initial
integer, public, parameter :: LOGGER_NAME_LEN = ID_LEN

Maximum length of logger name.


Derived Types

type, public ::  logger_class

Opaque logger class.

Type-Bound Procedures

procedure, public :: configure => logger_configure
procedure, public :: get_name => logger_get_name
procedure, public :: is_ipc => logger_is_ipc
procedure, public :: out => logger_out
generic, public :: log => log_args, log_type
procedure, public :: critical => logger_log_critical
procedure, public :: debug => logger_log_debug
procedure, public :: error => logger_log_error
procedure, public :: info => logger_log_info
procedure, public :: user => logger_log_user
procedure, public :: warning => logger_log_warning

Functions

public function dm_logger_get_default() result(logger)

Returns pointer to global logger. The function allocates the logger if it does not exist yet.

Arguments

None

Return Value class(logger_class), pointer

Pointer to logger object.