class Analogger::Core
- Analogger::Core
- Reference
- Object
Defined in:
analogger/core.cranalogger/core/daemonize.cr
analogger/core/exec_arguments.cr
analogger/core/log.cr
Constant Summary
-
DEFAULT_SEVERITY_LEVELS =
["debug", "info", "warn", "error", "fatal"].each_with_object({} of String => Bool) do |k, h| h[k] = true end
-
EXIT_SIGNALS =
[Signal::INT, Signal::TERM]
-
RELOAD_SIGNALS =
[Signal::HUP]
-
RESTART_SIGNALS =
[Signal::USR2]
Constructors
Class Method Summary
- .default_log : String
- .default_log=(default_log : String)
- .default_log_destination : Analogger::Destination::File | IO::FileDescriptor | Nil
- .default_log_destination=(default_log_destination : Analogger::Destination::File | IO::FileDescriptor | Nil)
Instance Method Summary
- #add_log(log)
- #any_in_queue?
- #check_config_settings
- #cleanup
- #cleanup_and_reopen
- #config : Config
- #config=(config : Config)
- #create_periodic_timers
- #daemonize
- #flush_queue
- #fsync_or_flush(dest)
- #handle(client)
- #handle_daemonize
- #handle_pending_and_exit
- #invocation_arguments : ExecArguments
- #invocation_arguments=(invocation_arguments : ExecArguments)
- #key : String
- #key=(key : String)
- #logfile_destination(logfile : IO, type : String | Nil = "file", options : Array(String) | Nil = ["ab"])
- #logfile_destination(logfile : String, type : String | Nil = "file", options : Array(String) | Nil = ["ab"])
- #normalize_levels(levels : String)
- #normalize_levels(levels : Array)
- #normalize_levels(levels : Bool | Nil)
- #normalize_levels(levels : Hash)
- #normalize_levels(levels : Int32 | YAML::Any)
-
#populate_logs
Iterate through the logs entries in the configuration file, and create a log entity for each one.
- #postprocess_config_load
- #purge_queues
- #safe_trap(signal_list : Array(Signal), &operation)
- #set_config_defaults
- #setsid
- #setup_signal_traps
- #sid(pid : Int32 = 0)
- #start
- #write_queue
Constructor Detail
Class Method Detail
def self.default_log_destination : Analogger::Destination::File | IO::FileDescriptor | Nil
#
def self.default_log_destination=(default_log_destination : Analogger::Destination::File | IO::FileDescriptor | Nil)
#
Instance Method Detail
def logfile_destination(logfile : IO, type : String | Nil = "file", options : Array(String) | Nil = ["ab"])
#
def logfile_destination(logfile : String, type : String | Nil = "file", options : Array(String) | Nil = ["ab"])
#
def populate_logs
#
Iterate through the logs entries in the configuration file, and create a log entity for each one.