Membrane Core v0.2.2 Membrane.Log.Router View Source
Defines a router that dispatches logs to instances of Membrane.Log.Logger.Base
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor
Converts atom with level to its number representation
Sends asynchronous call to the router, requesting it to forward log message to appropriate loggers
Starts router as a separate process
Link to this section Functions
Link to this function
child_spec(init_arg) View Source
Returns a specification to start this module under a supervisor.
See Supervisor
.
Link to this function
level_to_val(atom)
View Source
level_to_val(atom)
View Source
level_to_val(atom()) :: 0 | 1 | 2
level_to_val(atom()) :: 0 | 1 | 2
Converts atom with level to its number representation
Valid atoms are:
- :debug
- :info
- :warn
Link to this function
send_log(level, message, time, tags \\ []) View Source
Sends asynchronous call to the router, requesting it to forward log message to appropriate loggers.
This functions assumes that passed log has level equal or greater than global level.
Link to this function
start_link(arg)
View Source
start_link(arg)
View Source
start_link({any(), GenServer.options()}) :: GenServer.on_start()
start_link({any(), GenServer.options()}) :: GenServer.on_start()
Starts router as a separate process.
Options are passed to Supervisor.start_link/3
.