Safe Haskell | None |
---|---|
Language | Haskell2010 |
Documentation
A LogRecord
represents an event being logged.
LogRecord
s are created every time something is logged. They
contain all the information related to the event being logged.
It includes the main message as well as information such as when the record was created, the source line where the logging call was made.
LogRecord
can be formatted into string by Format
from vformat
package, see format1
for more information.
Currently, the useful attributes in a LogRecord are described by:
logger name of the logger, seeLogger
level logging level for the message, seeLevel
message the main message passed to logv debug info .. pathname full pathname of the source file where the logging call was issued (if available) filename filename portion of pathname pkgname package name where the logging call was issued (if available) modulename module name (e.g. Main, Logging) lineno source line number where the logging call was issued (if available) asctime locale time when theLogRecord
was created (TimeZone
is fromManager
) utctime utc time when theLogRecord
was created created timestamp when theLogRecord
was created msecs millisecond portion of the creation time threadThreadId
of the thread in which the logging call was issued
Format examples:
"{message}" "{logger} {level}: {message}" "{logger:<20.20s} {level:<8s}: {message}" "{asctime:%Y-%m-%dT%H:%M:%S%6Q%z} - {level} - {logger}] {message}"
LogRecord | |
|