io.tracee.backend.slf4j.Slf4jMdcAdapter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of tracee-slf4j Show documentation
Show all versions of tracee-slf4j Show documentation
Please refer to https://github.com/tracee/tracee.
package io.tracee.backend.slf4j;
import io.tracee.MDCLike;
import org.slf4j.MDC;
import java.util.Map;
final class Slf4jMdcAdapter implements MDCLike {
@Override
public boolean containsKey(String key) {
return MDC.get(key) != null;
}
@Override
public void put(String key, String value) {
MDC.put(key, value);
}
@Override
public String get(String key) {
return MDC.get(key);
}
@Override
public void remove(String key) {
MDC.remove(key);
}
@Override
@SuppressWarnings("unchecked")
public Map getCopyOfContext() {
return (Map) MDC.getCopyOfContextMap();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy