Safe Haskell | None |
---|---|
Language | Haskell2010 |
- data FastLoggerSettings = FastLoggerSettings {}
- data SyslogSettings = SyslogSettings {}
- defStdoutSettings :: FastLoggerSettings
- defStderrSettings :: FastLoggerSettings
- defFileSettings :: FilePath -> FastLoggerSettings
- defaultSyslogSettings :: SyslogSettings
- defaultSyslogFormat :: Format
- checkLogLevel :: LogFilter -> LogMessage -> Bool
Documentation
This module contains several implementation of logging backend. A backend is some kind of target, where your messages will go. Each backend has its own specific settings.
Backends provided are:
- Fast-logger backend. It allows to write messages to stdout, stderr or arbitrary file.
- Syslog backend.
- Chan backend.
data FastLoggerSettings Source #
Settings of fast-logger backend. This mostly reflects settings of fast-logger itself.
data SyslogSettings Source #
Settings for syslog backend. This mostly reflects syslog API.
SyslogSettings | |
|
Default settings
defStdoutSettings :: FastLoggerSettings Source #
Default settings for fast-logger stdout output
defStderrSettings :: FastLoggerSettings Source #
Default settings for fast-logger stderr output
defFileSettings :: FilePath -> FastLoggerSettings Source #
Default settings for fast-logger file output. This implies log rotation when log file size reaches 10Mb.
defaultSyslogSettings :: SyslogSettings Source #
Default settings for syslog backend
defaultSyslogFormat :: Format Source #
Default log message format fof syslog backend:
[{level}] {source}: {message}
Utilities for other backends implementation
checkLogLevel :: LogFilter -> LogMessage -> Bool Source #
Check if message level matches given filter.