Name | Date | Size | #Lines | LOC | ||
---|---|---|---|---|---|---|
.. | - | - | ||||
api/ | H | 25-Apr-2025 | - | 16 | 13 | |
src/ | H | 25-Apr-2025 | - | 117 | 33 | |
test/ | H | 25-Apr-2025 | - | 145 | 123 | |
test-resources/ | H | 25-Apr-2025 | - | 16 | 11 | |
README.md | H A D | 25-Apr-2025 | 756 | 27 | 16 | |
build.gradle.kts | H A D | 25-Apr-2025 | 324 | 11 | 9 | |
package.list | H A D | 25-Apr-2025 | 404 | 22 | 21 |
README.md
1# Module kotlinx-coroutines-slf4j 2 3Integration with SLF4J [MDC](https://logback.qos.ch/manual/mdc.html). 4 5## Example 6 7Add [MDCContext] to the coroutine context so that the SLF4J MDC context is captured and passed into the coroutine. 8 9```kotlin 10MDC.put("kotlin", "rocks") // put a value into the MDC context 11 12launch(MDCContext()) { 13 logger.info { "..." } // the MDC context will contain the mapping here 14} 15``` 16 17# Package kotlinx.coroutines.slf4j 18 19Integration with SLF4J [MDC](https://logback.qos.ch/manual/mdc.html). 20 21<!--- MODULE kotlinx-coroutines-slf4j --> 22<!--- INDEX kotlinx.coroutines.slf4j --> 23 24[MDCContext]: https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-slf4j/kotlinx.coroutines.slf4j/-m-d-c-context/index.html 25 26<!--- END --> 27