Kotlin Logging
We use quarkus logging as a lightweight logging framework for Kotlin.
The following api
dependencies are used for the configuration:
api("org.slf4j:slf4j-api:$slf4jVersion")
api("org.jboss.slf4j:slf4j-jboss-logmanager:$jbossLogManagerVersion")
Furthermore, the following dependencies are used to configure the log message format.
com.fasterxml.jackson.module:jackson-module-kotlin
com.fasterxml.jackson.datatype:jackson-datatype-jsr310
MDC Contextual Logging
We add implicit context data such as appId and transactionId to possible log messages via Mapped Diagnostic Context (MDC). We import MDC via:
A key-value pair is used at every endpoint via MDC.put(key, value)
to add a key and the corresponding value to the MDC.