All Downloads are FREE. Search and download functionalities are using the official Maven repository.

liquibase.logging.mdc.NoOpMdcManager Maven / Gradle / Ivy

There is a newer version: 4.30.0
Show newest version
package liquibase.logging.mdc;

import liquibase.plugin.Plugin;

import java.util.Collections;
import java.util.Map;

/**
 * Default MDC manager, which does nothing.
 */
public class NoOpMdcManager implements MdcManager {
    @Override
    public MdcObject put(String key, String value) {
        return new MdcObject(key, value);
    }

    @Override
    public MdcObject put(String key, String value, boolean removeWhenScopeExits) {
        return new MdcObject(key, value);
    }

    @Override
    public MdcObject put(String key, Map values) {
        return new MdcObject(key, values);
    }

    @Override
    public MdcObject put(String key, Map values, boolean removeWhenScopeExits) {
        return new MdcObject(key, values);
    }

    @Override
    public MdcObject put(String key, CustomMdcObject customMdcObject) {
        return new MdcObject(key, customMdcObject);
    }

    @Override
    public MdcObject put(String key, CustomMdcObject customMdcObject, boolean removeWhenScopeExits) {
        return new MdcObject(key, customMdcObject);
    }

    @Override
    public void remove(String key) {

    }

    @Override
    public void clear() {

    }

    @Override
    public int getPriority() {
        return Plugin.PRIORITY_DEFAULT;
    }

    @Override
    public Map getAll() {
        return Collections.emptyMap();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy