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

org.zodiac.autoconfigure.application.DefaultReactiveApplicatuonBootstrapAutoConfiguration Maven / Gradle / Ivy

There is a newer version: 1.6.8
Show newest version
package org.zodiac.autoconfigure.application;

import org.springframework.boot.SpringBootConfiguration;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication.Type;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.Bean;
import org.zodiac.core.logging.trace.ReactiveTraceLoggingMDCFilter;

@SpringBootConfiguration
@ConditionalOnWebApplication(type = Type.REACTIVE)
@AutoConfigureAfter(value = {DefaultApplicatuonBootstrapAutoConfiguration.class})
public class DefaultReactiveApplicatuonBootstrapAutoConfiguration {

    private final ApplicationContext applicationContext;

    public DefaultReactiveApplicatuonBootstrapAutoConfiguration(ApplicationContext applicationContext) {
        this.applicationContext = applicationContext;
    }

    @Bean
    @ConditionalOnMissingBean(value = {ReactiveTraceLoggingMDCFilter.class})
    protected ReactiveTraceLoggingMDCFilter defaultTraceLoggingMDCFilter() {
        return new ReactiveTraceLoggingMDCFilter(applicationContext) {};
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy