Class | Description |
---|---|
CompletionExceptionLogHelper |
Helper class for helping with logging of
CompletionException s. |
KeyValueLogMessage |
A formatter for log messages.
|
Enum | Description |
---|---|
LogMessageKeys |
Common
KeyValueLogMessage keys logged by the Record Layer core. |
TestLogMessageKeys |
Common
KeyValueLogMessage keys logged by the Record Layer core. |
Exception | Description |
---|---|
CompletionExceptionLogHelper.IgnoredSuppressedExceptionCount |
A special "exception" to record the number of suppressed exceptions that were not recorded due to the
CompletionExceptionLogHelper.maxSuppressedCount . |
All logging is done using SLF4J, which should be compatible with whatever logging framework the client system uses.
All Logger
s have names starting with com.apple.foundationdb.record
.
Log messages of any complexity use KeyValueLogMessage
, which outputs in a standard key=value
format.
Most of the standard log message keys appear in LogMessageKeys
.
Since record operations are fundamentally asynchronous and makes extensive use of CompletableFuture
composition, log messages for a single operation will
often come from multiple thread pool threads. To allow these to be associated with a calling context in the log, the MDC
is used.
FDBDatabase.openContext()
takes an optional MDC map, which will be maintained for all work done by the FDBRecordContext
.