heavy-logger-0.1.0.0: Full-weight logging based on fast-logger

Safe HaskellNone
LanguageHaskell2010

System.Log.Heavy.Backends

Contents

Synopsis

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.

Constructors

FastLoggerSettings 

Fields

Instances

data SyslogSettings Source #

Settings for syslog backend. This mostly reflects syslog API.

Constructors

SyslogSettings 

Fields

Instances

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.