more comments

Signed-off-by: Ceki Gulcu <ceki@qos.ch>
This commit is contained in:
Ceki Gulcu 2024-01-23 15:51:31 +01:00
parent 6b2921a523
commit 8c4ea8f225
1 changed files with 3 additions and 0 deletions

View File

@ -91,6 +91,9 @@ public class MDC {
static { static {
SLF4JServiceProvider provider = LoggerFactory.getProvider(); SLF4JServiceProvider provider = LoggerFactory.getProvider();
if (provider != null) { if (provider != null) {
// obtain and attach the MDCAdapter from the provider
// If you wish to change the adapter, Setting the MDC.mdcAdapter variable might not be enough as
// the provider might perform additional assignments that you would need to replicate/adapt.
mdcAdapter = provider.getMDCAdapter(); mdcAdapter = provider.getMDCAdapter();
} else { } else {
Reporter.error("Failed to find provider."); Reporter.error("Failed to find provider.");